The storage of carbon dioxide by injecting carbon dioxide into gas reservoirs has become an important technique for achieving carbon capture, utilization, and storage. However, most studies have focused on tight gas reservoirs, and there are still few studies on the injection of carbon dioxide into water-bearing gas reservoirs. This paper analyzes the variation of reservoir pressure during CO2 injection and points out the optimal amount of CO2 injection in the reservoir, which can provide theoretical guidance in practical applications. The relationship is plotted between the formation pressure and the volume of injected carbon dioxide. The effects of reservoir inhomogeneity and the water content on the formation pressure are discussed. Dynamic monitoring of the formation pressure during carbon dioxide injection is achieved. The optimal volume of injected carbon dioxide for water-bearing gas reservoirs is determined. The results show that the formation pressure increases with an increase in the volume of injected carbon dioxide, and the curve exhibits a trend of steep increases at both ends and a gentle increase in the middle. Enhanced reservoir inhomogeneity and a low reservoir water content are favorable for carbon dioxide injection.