Pushing it in does turn it on/off which makes me wonder if there is a bad contact inside your radio and pulling it helps to put space between the contacts keeping vibration from turning it on/off.
I’m having the same problem with 2010 elantra and have no clue how to fix it.Pushing the knob after the radio shuts off itself does not turn it back on. I can push it 100 times and nothing. It will go on/off while the cars idle. Although it feels like sometimes if I just barely hit the gas it'll shut off or if I brake a little it turns off if on. But what would make it fix itself. I drive for 10ish minutes and it just starts working fine. I mean, it's fixed now I hope for good. Even if I just turn on the power, not engine it'll do this. So nothing vibrates at all causing it to malfunction.