If you install complex software like Alfresco or Odoo using the default provided installers, the components they rely on will usually be installed as separate / independent components. Such installers are usually meant for "quick start" type of scenarios - I don't see them fit for best practices / production use cases.
You can avoid conflicts between two PostgreSQL services by configuring their network ports to different values in their respective postgresql.conf files. This means you will also have to adapt the configuration of at least one of Alfresco or Odoo to use the changed port(s) for connecting to PostgreSQL.
What I'd do is a bit different. I would not install PostgreSQL service that is shipped with either installer. Instead I would install PostgreSQL (using an installer comming directly from PostgreSQL) as a single, shared service that provides databases for both business applications.
I took your last suggestion, installed odoo and alfresco by themselves without postgreSQL, installed postgreSQL separately from their official page but I don't know what to do next, I been trying move around pgAdmin 4 and connect to alfresco without success.
Hmm - I don't know how to actually help you if those steps are already confusing. I mean, you didn't even mention "what" about them is confusing to you so I could potentially try and explain one or two of them.
Any suggestions I might make might just confuse you more...
look, heres the thing.. alfresco is running in my local server pretty well, but I want to know and be ready when a new version of Alfresco Community comes out so I can have a backup done of my current alfresco's settings, repository, users, permissions, sites... so I can set up the new version of Alfresco Community with all of these settings, this is why I'm trying to understand how PostgreSQL works, pgAdmin, etc.
I wish there were more specific tutorials about this