The shell session is being executed by the system's /bin/bash instead of the bundled Bash at /Volumes/OpenFOAM-vXXXX/env/bin/bash, leading to the following message:
The default interactive shell is now zsh.
To update your account to use zsh, please run `chsh -s /bin/zsh`.
For more details, please visit https://support.apple.com/kb/HT208050.