When you increase the pressure of a gas a constant temperature:
- Below the critical point, at some pressure that depends on the temperature, some of the gas coalesces into a liquid fraction. At this constant temperature, pressure is constant, and the proportion of liquid depends on the volume you give.
- Above the critical point, the temperature is stronger than the attraction between the molecules, and no liquid forms.
Though, enough pressure will get the gas' density very similar to a liquid, and you will still observe a dip in the gas' density curves near the critical temperature, but no liquid separates from the gas.
These are typical conditions (density similar to the liquid) where laws of perfect gas do not apply.