This clip from the Physical Chemistry book explains how concentration changes with pressure. Changing the pressure on a gas can change the number of moles.
This leads us to the concept of the chemical potential: each compound has a potential to react and has its own molar Gibbs free energy. The greater the chemical potential is negative (at constant T and P) the greater the potential to react and minimize the Gibbs energy for the whole reaction.