Mage" is the term for any spell-caster.
In D&D, a wizard casts spells that he has prepared at the beginning of each day, selected from the entire list for his level. A sorcerer has a certain number of spells that he can cast spontaneously, but he can only choose from a limited selection of spells, which he determines ahead of time (when he gets more spells, like when he levels up). In addition, wizards usually have to carry around spellbooks.
"Warlock" is another word for wizard, particularly when compared with "witch" (a warlock is a male witch). As far as I know, that term is not used in role-playing games (although there may be a few obscure ones that use it).