Apple ID shouldn't be required for that (unless you're downloading it from the Apple Developer site instead of installing through macOS directly?).
(Homebrew also just installs it automatically now, without needing any user intervention.)
EDIT: Maybe you were put off by the insane time estimate that it presents for some reason? It quotes a multi-day installation time that ends up only taking a few minutes. Maybe Apple will fix that someday.