We've learned that energy can neither be created nor destroyed. So, my question is since humans have energy within them and after they die what happens to the energy which is within them?

The energy present in the body of a dead person doesn't escape instantly but stays in the body.

Later when the body is buried, it decays and the energy is released to the soil. If the body is burnt instead, the energy is released to atmosphere. This is a part of carbon cycle.