Install pyenv. pyenv is the package manager used for installing multiple versions of python.
brew install pyenv
pyenv install 3.8.16
Set python3.8 as your global language.
pyenv global 3.8.16
Verify your work
Step 1 - Install Anaconda via Homebrew
Anaconda is a Python-based toolbelt for data scientists. You can install it using a distribution file or via Homebrew. I always pick Homebrew when possible. It will help you better understand where your libraries live.