How to add a page to the WordPress admin sidebar menu
This is a brief guide on how to add a custom top-level menu item and corresponding admin screen to the WordPress admin sidebar.

The code in this tutorial can be added to your theme's functions.php, added using a code snippets plugins like Code Snippets, or elsewhere in a custom plugin or child theme.
Step 1: Add admin menu hook
First, let's add an action for theadmin_menu hook.Let's take a look at the options we have available in add_menu_page. Here is the function prototype:
1. page_title – Title of the page used in the title tags.
2. menu_title – Text to be displayed in the sidebar.
3. capability – The capability required for this menu item to be displayed. "manage_options" is a good choice to restrict access to Administrators.
Read more at WordPress Roles and Capabilities
4. callback – The function that will output the content for the page.
5. icon_url – Optional icon for the class.
You can use icons here WordPress Dashicons
6. position – A priority number to control the relative position of the element in the sidebar.
Read more here: WordPress add_menu_page documentation
Step 2: Output the contents of the page
Define the function in your callback from Step 1. Use any method to output the necessary HTML.And we are done! You should now see your menu on the sidebar and your content should display when you select it.
Full Example