In addition to the other comment mentioning rpm-ostree, brew is installed on bazzite by default and works about as well as it does on macOS.
You can also use fedora toolboxes to create containers mounted on your home folder, though it is clunky.