Shortcut key for fullscreen mode I am new to Mac OS (2014 Macbook Air).
I am looking at the arrow on top right corner of windows, when I click it, it maximizes window over the top menu and in order to switch back I need to hold mouse in top right corner in order for menu to appear and the button with arrows appears again to [kind of] minimize back as it was.

Is there a shortcut key to switch between these modes ? I could only find the Command+M shortcut which completely minimizes the window.
The button in the top right of each window is not for minimizing and maximizing the window, but for putting it in and out of fullscreen mode (which is why it covers the menu bar, as you said). 

The keyboard shortcut to toggle fullscreen depends on the application.

Most applications that I use on a daily basis (such as Google Chrome, Terminal, Mail, and Safari) use ^+⌘+F (Control+Cmd+F) to toggle fullscreen mode.

Unfortunately, not all developers use this shortcut in their applications. iTerm, for example, uses ⌘+Enter to toggle fullscreen mode. If the application you refer to does not use either of these shortcuts, you should look for the fullscreen option in the View menu or by searching for "fullscreen" in the Help menu.