Heteroatoms can alter the electronic density around the active sites, influencing the adsorption and activation of reactants. For instance, nitrogen doping in carbon-based catalysts can introduce basic sites that enhance the adsorption of acidic molecules like CO2. Additionally, heteroatoms can also affect the physical properties, such as the surface area and porosity of the catalyst, further impacting its performance.