With my Windows computer I could control the power button action.
I was a bit disappointed that you cannot control this action on a Mac. But now I found out that there is a keyboard shortcut to instantly shutdown your mac.
CMD + alt + ctrl + Power button
I know it is a horrible shortcut, but it works!!