Mahisha performed severe penances for Lord Shiva, Lord Brahma pleased with his penance and came him to give a boon.Mahisha asked for immortality, which the Lord said he could not have give that boon because as every creature that was born had to die. Then he asked that no man should be able to kill and, if he had die it should be only in the hands of women. He was sure that no women could ever fight against him.
Mahisasura Mardini is the incarnation of Goddess Durga who had taken birth to kill the demon Mahisasura, he has a magical power to take the form of baffalo and human according to his wish. Mahishasura was invincible, he and the other asuras went about hurting and killing every one on the earth as well as Deva Loka by attacking Lord Indra. All Gods approached Lord Vishnu for a solution. Thus the powers of trinity of Lord Brahma, Lord Shiva and Lord Vishnu joined together for the creation of Goddess Durga. Goddess Durga was incarnated with ten arms, each having different warriors with lion as her vehicle.
When Mahishasura saw Durga on the battlefield, he fell in love instantly, enthralled by her beauty, he proposed to marry her. Durga agreed, but on one condition, Mahishasura would have to defeat her in battle.
Then began a fierce battle between the two and their armies of devas and Asuras, the fighting continued for nine days and nights with much gore and destruction. Finally on the tenth day, Durga had the upper hand and Mahishasura, desperately trying to avoid defeat, transformed into wild buffalo. Durga pinned him to ground with her left leg, Finally Mahishasura killed in the hands of Durga Devi.