To an extent it measures the number of molecules above you. In physics, pressure is defined as force per unit area. The atmospheric pressure is always changing since the weight of the air above you changes.
Molecules move in and out based on air motions and temperature.
Usually the higher the temperatures near the earth's surface the lower the air pressure, while colder temperatures produce higher pressure. The world's highest pressure record, for example, occurred under a bitter cold dome of air. During a Siberian cold wave the pressure in eastern Russia got up to 32.005 inches. In contrast, the lowest pressure on record in the world took place in the eye of a Pacific Typhoon. Typhoons are what they call hurricanes west of the International Dateline.