Lord Brahma, the supreme creator, was filled with pride because of the beauty of his creation, and kept talking of his own glory. The Devas could not bear this, and asked Lord Shiva to punish Lord Brahma. Lord Shiva agreed, but said that he would wait till Lord Brahma made a mistake.
The Devas decided to send Brahma meet Lord Shiva, with the hope that sooner or later, Brahma would do something wrong. Shiva was out on his daily tour of the world. Parvati saw Brahma (with his five heads) and thought that Lord Shiva (also with five heads) had returned. She started worshiping his feet (Paada Pooja) without looking up at his face, while Brahma stood silently.
Just at that moment, Lord Shiva returned. He saw and realized Parvati’s mistake. He got angry at Brahma, for Brahma knew Parvati was making a mistake, but Brahma did not correct the mistake.
Shiva then plucked off one of Brahma’s heads (Kapalam), as it was the fifth head of Brahma that caused the problem. Brahma thus became four-headed. Shivji (Eeshwarar) thus also came to be known as Kapaleeshwarar.