I can change the color of the Jframe background from the Jpanel,
You are not changing the color of the frame. You are changing the color of the panel. The panel covers the entire frame.
You added the MenuPanel to the content pane of the frame. The panel fills the entire content pane so you see the color of the panel, not the frame.
A couple of problems with this statement:
1. Class names should start with an upper case character.
2. You should NOT be extending JFrame. There is no need to extend any class. You are writing an ActionListener. All you need to do is implement the methods of the ActionListener.
Again, you can't change the content pane because the panel cover the entire content pane. You can change the color of the panel with code like
I suggest you read the Swing tutorial on Using Top Level Containers for some Swing basics. Keep a link to the tutorial handy. It will also show you other Swing concepts, like how to use listeners.