These types of stories are called "myths" and all the myths of a nation collected are called the mythology. Famous examples of mythologies are Greek Mythology (gods such as Zeus, Hercules, and similar), and Egyptian Mythology (gods such as Osiris, Anubis, and similar).
Myths tends to created when people in the past try to explain things that they understand without using scientific process, which resulted in a grand story that cannot be proven.
For example, in the past people do not understand why thunderstorm of created. Because of this, they made up a story on how a God in the sky throwing the thunders on Earth because He was angry at the people.