There are two basic types of coffee grinder available:
A blade grinder and a burr grinder.
Burr grinders use grinding wheels to crush coffee beans, which are adjustable for grinding from course grinds to very fine grinds. The fully adjustable grind control will depend on the machine you are using to make coffee, or the type of coffee you enjoy - course grinds are needed for filter coffee makers and very fine grinds are needed for espresso. The coffee only passes through the grind cones once so it preserves the flavour of the coffee. Burr grinders are generally seen as a more professional approach than blade grinders although they are more expensive. If you enjoy espresso coffee, paying a little extra for one of these is well worth it. Burr grinders are not suitable for spices.
Blade grinders use blades to chop up the coffee beans, rather like a mill jar. The longer you hold the button down, the finer the grind will be. They are less expensive than burr grinders although they can be noisier. This type of grinder can also be used as a spice grinder, although it can affect the taste if it is subsequently used for coffee without proper cleaning.