The utilization of nitrogen for enhanced coalbed methane technique offers a promising solution to tackle the greenhouse effect, energy crisis, and coal mine accidents. In this research, a gas flooding experiment utilizing COMSOL 6.1 software was performed. The outcomes demonstrated that the concentration of gas, rate of gas flow, and permeability at a specific moment were directly proportional to the pressure of gas injection. Nonetheless, the pressure of nitrogen decreased as the distance of gas injection increased. Throughout the simulation, the coal displayed two distinct stages of elasticity and plasticity, with the gradual increment of equivalent stress due to continuous gas injection. Damages occurred in the localized circumferential region of the coal when the maximum tensile stress surpassed 3.5 MPa, which led to the formation of new fractures and facilitated gas leakage. The study uncovered the mechanism of nitrogen injection-enhanced coalbed methane under varying gas injection pressures. Injecting nitrogen into the coal can increase the concentration difference and pressure gradient, resulting in a noticeable equivalent force effect. This enhances methane self-desorption that causes the coal matrix to shrink, and increases the permeability. Conversely, when the pressure at the outlet decreases to atmospheric pressure, the gas driving energy decreases, leading to a reduction in the permeability. The interconnection between pressure, seepage, and stress deformation fields is elucidated. These research discoveries can serve as a valuable resource for practical ventures.