To build a wall closet, determine the closet's boundaries as per the stud location. Cut 2-by-4 lumber for the front walls of the closet and screw it to the floor and ceiling. Attach closet studs, frame the closet's door, cut and secure the drywall, and affix the doors.
Choose an area in a room for the wall closet that does not interfere with its use or any ceiling fixtures. Mark and measure the boundaries of the closet using a measuring tape. Mark the existing stud locations under the drywall and adjust the closet size accordingly.
Make the closet's front walls using 2-by-4 lumber. Attach it to the floor and the ceiling using long and drywall screws, respectively, inserted diagonally. Affix closet studs at every three feet of the closet's length. Make the door frame the required size. If desired, install electrical boxes and cables in the closet.
Cut drywall to the size required using a saw with a fine drywall blade and attach it to the closet frame with drywall screws. Finish the existing wall and drywall joints using drywall joint compound and tape. Sand the compound's edges. Apply a texture compound on it and allow it to dry.
Affix the closet's doors. Leave approximately 1/2 inch floor clearance. Raise the height of the door frame from the floor using shimming if there is a thick carpet.