States of matter

Why is fugacity used in real-gas thermodynamics?