It's more like the capitalism that causes buildings to require AC to be liveable is causing the heat deaths primarily through other mechanisms.
If capitalists are going to put people in cheaply manufactured highly individualized single-family housing that is not adapted to local climate conditions with the explicit intent of fragmenting communities and making people dependent on mass consumption for basic needs, then some of those people are going to need AC to survive. The people using AC to survive are not responsible for the AC emissions, the system that made it necessary for them to use it is.