All Jyotirlingas did not form at once. There is a story behind every Jyotirlinga that was formed what is its purpose. For instance, it is believed that Daaruka (a demon) took Supriya and others to his city, Darukavana, a city under the sea. They all prayed to Lord Shiva who appeared and vanquished Daaruka. Since then, Lord Shiva resided there in the form of a Jyotirlinga.