Yes mayonnaise is good for burns as long as you wait to put the mayonnaise on the burn after the burn has cooled down.
Do not put mayonnaise on the burn while the burn is still hot or has just happened as it could make it worse.
When you get burned you should first run cool water over the burn to cool it down and then apply a cold compress.
Then after the burn cools down you can add some mayonnaise or butter etc to the burn to help soothe it down.
You can also apply some Aloe Vera Gel to the burn to help soothe it.
More severe burns require medical attention but less severe burns can usually be treated at home.
Honey is also good for burns and taking pain relievers such as aspirin can help heal the burn and soothe it.