How do I open a real forex account on MetaTrader 4?
To open a real MT4 forex account you must do so through your forex brokers portal (via their website or mobile app). MT4 is not equipped with account opening capability. After opening the account, your forex broker will send your login details to your email so do well to check your mail. Take the login details then use it to login on the MT4 platform; the login details will usually contain a server name so ensure to select the correct server as this is crucial.
You asked why account opening feature wasn't integrated into MT4, well in my opinion MetaTrader is an open third-party platform used by different brokers so integrating account opening for each broker will require frequent modification of the MetaTrader app, which can affect its stability.