I want to do a pause panel

I have a problem at selecting button Pleas help
Thx

using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.UI;


public class PauseManu : MonoBehaviour
{
    public static bool GameisPaused = false;
    public Button escape;
    public GameObject pauseMenuUI;

    void Update()
    {
        if (Input.GetButtonDown(escape))
        {

u could set the pause menu to active if escaped is pressed and have it set to inactive when a button on the pause menu is pressed and at the start like this

using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.UI;


public class PauseManu : MonoBehaviour
{
    public static bool GameisPaused = false;
    public Button escape;
    //added button variable for resume(this could be space or something)
    public Button resume;
    public GameObject pauseMenuUI;

    //added start function that runs as soon as the script is to set the pause menu to inactive
    void start()
    {
        //added action to start function to set the pause menu to inactive
        pauseMenuUI.SetActive(false);
    }

    void Update()
    {
        if (Input.GetButtonDown(escape))
        {
            //added action to if statement to set the game object to active when escape is pressed
            pauseMenuUI.SetActive(true);
        }
        //added if statement to check every frame for when the resume button is pressed
        if (Input.GetButtonDown(resume))
        {
            //added action to set te pause menu back to inactive after resume button is pressed
            pauseMenuUI.SetActive(false);
        }
    }
}

@iHadigamer