Answer:
Because the gravity of the Earth is pulling on air molecules and pressing it against the ground, our atmosphere is thinner and thinner the higher up you go.
Step-by-step explanation:
As all bodies in space, Earth has its own gravity, defined by its mass. For a planet of the size it is, Earth's gravitational pull can be considered as a normal one. Basically, the gravitational pull is the force that is dragging the objects toward it, in this case toward Earth's surface.
The atmosphere is not immune to this, and that can easily be noticed by the density of air in the lower parts of it and further up. The gravity has pulled the majority of the gases toward Earth's surface so the air is by far the densest in the troposphere (the lowest part of the atmosphere). As we go higher and higher up, the air becomes less and less dense, and in the highest layer, the molecules are so far apart that it is hard to distinguish it from space.