This is a quick and easy one, but I haven't actually seen many tutorials deal with a proper way to pause your game directly, most of them just have you freeze time and maybe deactivate a script or 2.
This way is a one-and-done method that you won't need to worry about because it scales perfectly.