According to Adi Parva of Mahabharata Lord Shiva had imprisoned four Indras in the cave of mountain.
The illustrious Isana of fierce energy then said unto him, 'Act not, O Sakra, ever again in this way.Remove this huge stone, for thy strength and energy are immeasurable, and enter the hole (it will disclose) where await some others possessing the splendour of the sun and who are all like unto thee.' Indra, then, on removing that stone, beheld a cave in the breast of that king of mountains, within which were four others resembling himself.
So the conclusion is that Lord Shiva had Imprisoned four Indras in the cave and further the fifth Indra ( that was the Indra of that time ) get imprisoned by him.