 In order to deceive Tharukasuran, the devas transformed into ants and reached the temple.Since the surface of the lingam (aniconic form of Shiva) was slippery, the ants found it difficult to climb up and worship.Shiva transformed himself into an ant hill and slid his head, which enabled the ants to climb and worship.