Guitar finishes typically are nitrocellulose lacquer, which is a hard, almost bulletproof finish that protects the guitar for the lifetime of the instrument. Occasionally, you bump your guitar, accidentally drop it or bang it into something and get a ding in the finish. You don't need to sand off the finish to remove small dents. You can spot-finish them by filling in the dent with regular lacquer.
Tape around the ding with masking tape. Lay the tape as close to the perimeter of the ding as possible.
Dip a cotton swab into the lacquer. Touch the lacquered swab to the ding, leaving a small drop of lacquer in the ding. Wait 30 minutes for the lacquer to dry. Apply more lacquer, one drop at a time. Let it dry, and continue to apply more lacquer until the dried lacquer is slightly higher than the surface of the guitar body.
Sand the lacquer down with 400-grit sandpaper until it is flush with the guitar body. Remove the tape. Spot sand around the ding. Sand a circle around the ding, just barely wider in circumference than the ding.
Dip the end of a cotton swab in polishing compound, and apply a drop of it to the ding. Use a cotton cloth to polish the sanded area. Use a circular motion with the tip of your finger for 5 minutes.
Wipe the area clean with a dry cloth, and polish over the area with another clean, dry cloth until the area is shiny and the ding is blended into the finish.
If your guitar is finished satin, buy satin lacquer. If it is finished glossy, buy glossy. Buy standard lacquer; you don't need to use nitrocellulose lacquer. You can buy polishing compound at any guitar supply company online or at a local auto parts store.
Always wear breathing protection when sanding or working with wood or finishing products.