Apple - Can't install Homebrew on macOS Mojave; installer doesn't recognize Command Line Tools
Xcode command line tools is a separate package for Xcode
Download Command Line Tools for Xcode from developer.apple.com/download/more and install it again.
source: Installing Xcode Command Line Tools
Useful for troubleshooting
xcode-select -p