Rebuilding. Enamel is made up of complex crystals of calcium phosphate and organic material. These crystals lose calcium etc as theydemineralize. If the damage isn't too extensive calcium and phosphate from the saliva is taken and the crystal structure remineralized/repaired. Fluiride, if available, can also be incorporated in this structure making the crystal more resistant to acid attack.
Chemical change. Natural enamel is made up of hydroxyapetite and when it demineralizes (from sugar/acid) the hydroxide leaves and weakens/softens the struture of the tooth. Fluoride is the replacement that comes in and replaces the hydroxide and you get fluorapetite which is more compact and harder. You are not growing enamel, just hardening it back up.