Before you install the door you need to perform other works.
At what stage of repair interior doors are installed : Before You Install The Door You Need To Perform Other Works.
Quote from Article entitled At what stage of repair interior doors are installed:
There are several variants:If you need to expand a doorway, it is better to do all this work to the final smoothing of a room, or a large amount of dust settles on clean walls and ceilings.If a door frame is exactly fitted to the size of an opening, it is correct to set up doors after final smoothing of walls and ceilings not to damage a new door during repair.Many professionals use the method of the phased installation: set up a door frame before final smoothing of ceilings and walls and a door leaf and casings after it. This variant eliminates the dirtying and damage of new wallpaper or painted walls when installing a frame, and at the same time, a wood leaf will not draw moisture and rot during painting and pasting when indoor humidity is very high. In this case, in order to avoid damage and contamination, a set frame is better to paste over with masking tape, and then to remove it, after all dirty works, before installing the door.
The full version of the article can be found here.