in the terminal (Ctrl+Alt+T) you can type
$ apt show postgresql
and see if postgresql is known
let me see the response
this is simpler than copying from the package manager
again in the terminal, let’s make sure you are using the most current releases of the software that is already installed
$ sudo apt -y upgrade
Now we are going to install (or reinstall, or do nothing) postgres and friends. There is no harm if you have these programs installed already. Doing these next steps assures that you will have what you need of postgreSQL. From the terminal:
$ sudo apt-get install postgresql
$ sudo apt-get install postgresql-client
$ sudo apt-get install postgresql-contrib
$ sudo apt-get install pgadmin4
after that is done, you can confirm that PostgreSQL is ready for use (let me know when you get here, or if you encounter something unexpected). Once here, please restart your machine. It is helpful to begin with a clean environment.