To enhance the low-carbon level and economic performance of microgrid systems while considering the impact of renewable energy output uncertainty on system operation stability, this paper presents a robust optimization microgrid model based on carbon-trading mechanisms and demand–response mechanisms. Regarding the carbon-trading mechanism, the baseline allocation method is utilized to provide carbon emission quotas to the system at no cost, and a ladder carbon price model is implemented to construct a carbon transaction cost model. Regarding uncertainty set construction, the correlation of distributed generation in time and space is considered, and a new uncertainty set is constructed based on historical data to reduce the conservative type of robust optimization. Based on the column constraint generation algorithm, the model is solved. The findings indicate that upon considering the carbon-trading mechanism, the microgrid tends to increase the output of low-carbon units and renewable energy units, and the carbon emissions of the microgrid can be effectively reduced. However, due to the increase in power purchase from the distribution network and the increase in carbon transaction costs, the operating costs of the microgrid increase. Secondly, through the utilization of demand–response mechanisms, the microgrid can achieve load transfer between peaks and troughs. It is imperative to establish appropriate compensation costs for demand and response that balances both economic efficiency and system stability. At the same time, due to the time-of-use electricity price, the energy storage equipment can also play a load transfer effect and improve the system’s economy. Finally, sensitivity analysis was conducted on the adjustment parameters of distributed power sources and loads that have uncertain values. A comparison was made between the deterministic scheduling model and the two-stage robust optimization model proposed in this study. It was proved that this model has great advantages in coordinating the economy, stability and low carbon level of microgrid operations.