According to Elmhurst College, gas exerts pressure due to the force gas exerts on a container's walls. An example is a person blowing up a balloon. The walls of the balloon expand due to the pressure of the air molecules inside the balloon being greater than that on the outside.
Pressure as a property determines the directional flow of mass. Using the balloon as an example again, the pressure of the air causes the balloon to leave a region of high pressure and enter a region of low pressure. Robert Boyle developed the first systematic study concerning the relationship between pressure and volume in gases.