A compass is a magnetized needle that, when allowed to move freely, points in one direction, and that is Magnetic North. This needle gives you a reference point for measuring all other directions.
All compasses do essentially the same thing, but more expensive models offer more features that make them easier to use. One convenient feature is a liquid filled capsule that slows the needle down. A compass with a rectangular base is easier to use with a map than a round compass. Compasses with features such as rotating dials, built in declination settings, and direction of travel arrows simplify compass use.