In the derivation of a general heat conduction equation for a differential element we apply the principle of conservation of energy. According to which
(Net heat conducted into element)+(Internal heat generated)=(Increase in internal energy)
Isn't the internal heat generation happening at the expense of internal energy so how can it increase the internal energy. For example if we consider an exothermic chemical reaction happening inside a control space then wouldn't the heat generation happen at the expense of internal energy of the system assuming the chemical substance is part of the system.