Pick a password.
Blank passwords are a Bad Idea for a networked system, and bad for at least two reasons.
Change the login password on Mac - Apple Support
Then follow the Homebrew installation instructions.
Have a complete backup before installing Homebrew too, as it can sometimes cause issues.
The terminal user guide is not going to be particularly helpful for the shell itself, and the Apple scripting primer that the terminal manual used to (still does?) references is rather outdated, as the current shell is zsh.
For a quick overview of (older, no longer the default) bash commands and syntax: https://devhints.io/bash
bash reference card: https://www.cheat-sheets.org/saved-copy/bash_ref.pdf
For a quick overview of zsh commands and syntax: https://devhints.io/zsh
zsh reference card: https://www.bash2zsh.com/zsh_refcard/refcard.pdf
I’d suggest spending more time with zsh than with bash, if macOS is your platform. This as Apple is migrating folks from bash to zsh, and as the installed version of bash is very old.
Use zsh as the default shell on your Mac - Apple Support
This is the (old) primer focusing on bash shell scripting available, as well: Introduction
For those with some familiarity with bash now looking at zsh: https://scriptingosx.com/2019/06/moving-to-zsh/
If videos work better for you:
https://academind.com/tutorials/terminal-zsh-basics
https://www.youtube.com/watch?v=ogWoUU2DXBU
And some links to other resources:
https://denshub.com/en/free-resources-to-learn-zsh/
ps: macOS is most definitely not Linux, and various Linux shell commands will not work on macOS.