Depending on the used platform, there are different ways to install Hugo.
There are different alternatives to the installation, but it most often makes the most sense to use the pre-compiled version.
Simplest way is to use Snap packages for installation.
sudo snap install hugo
sudo snap refresh hugo
For macOS, it makes sense to install Hugo from Homebrew package management:
brew update && brew install hugo