UUID instead of INT auto-increment

I’m not sure this is what I’m looking for. This seems like an extra field like uid but with a uuid format.

What I’m looking for is to change the id type to a uuid and have it generated in the database, not in code. Like using the Postgres UUID type, not a string.

This would mean the ID fields, all the foreign keys in the relation tables, etc…