Photons are quanta of energy that can behave like particles. But they are not 'stored' in the system in the form of 'particles'. They are the result of the interaction of your system with other systems or the environment.
So, you should ask yourself: if I have energy coming out of my system (one electron, or one atom, or an ensemble of atoms like a solid piece of tungsten), where do this energy come from? The (most likely) answer is that it comes from your system: you had an amount Ei before the interaction, you have an amount Ef after the interaction.
When you do the bookkeeping with the simplest systems you find out that the energy released is quantized in chunks that we call photons.
Sorry, but I am not going to waste my time in writing a deeper answer to a question that will be closed, but let me add this to address the core of your question: the photon energy comes from the electromagnetic field of the circuit composed by the battery, the ideally perfectly conducting wires and the resistor (the tungsten filament in the light bulb). Assuming a steady state current is flowing, if you compute the electric and magnetic field around the circuit you will find a configuration like this

source: Ian M. Sefton, "Understanding Electricity and Circuits: What the Text Books Don’t Tell You", Science Teachers’ Workshop 2002
where the Poynting vector goes from the battery to the resistor, guided by the conductors. This is the flow of energy shown by classical electromagnetism. What is not shown is the energy flowing out of the resistor in the form of infrared photons.
If we consider photons as quanta of energy, the question becomes where does the energy released as IR light from a resistor come from?
Of course it comes from the battery (where could it come from, a nuclear explosion?) but once the energy has flown from the battery to the resistor as predicted by Poynting, explaining the energy conversion mechanism taking place in a resistor is all but simple.
The electron-phonon (yes phoNon, NOT phoTon) interaction by which the electrons accelerated by the field transfer energy and momentum to the lattice is inherently linked to the electrical conduction process and is crucial to correctly explain the dependency of the material's resistivity on temperature. (It also explains quantitatively the relationship between electric and thermal conductivity - the Wiedemann-Franz law.) Then, IR energy can be explained as a result of the semiclassical conversion of vibrational lattice energy into electromagnetic radiation via (mostly) electric dipole radiation. But on EESE, for some reason, this has nothing to do with electronics.