Why do red giant stars produce energy?
They have a lot of mass.
All stars produce energy due to the same thing, mass. In the case of stars the huge mass produces a crushing gravitational force. This force is so strong it actually causes particles to fuse, creating heavier elements and releasing energy.