Measure and mark the molding location using a level. Cut the molding at 45-degree angles for inside corners and 90-degree angles for outside corners using a miter or coping saw. Apply adhesive and nail or staple the molding onto the wall. Seal gaps with caulk.