see http://nvm.sh
https://github.com/nvm-sh/nvm/blob/master/README.md#install–update-script and run the script that starts with wget:
It should look like this:
wget -qO- https://raw.githubusercontent.com/nvm-sh/nvm/v0.39.1/install.sh | bash
But go copy the script from the link, cause the version might change.
After you do this, close and reopen your terminal.