This is false.
Apple doesn’t actively discourage anything. Apple put all of options in the operating system for a reason and ships with a Terminal.
The GUI allows regular people to get shit done without requiring them to be experts.
Meanwhile, developers, hackers, tinkerers, can tweak to their heart’s content on the things that matter to them while getting the benefits of the Apple ecosystem. It’s never been an either/or.
Editing a config file on Linux isn’t inherently “better” than doing the same on macOS.
As for tweaking, the two major tweaks I depend upon are remapping Caps Lock as Compose (Karabiner lets me do that, along with some stuff I found that lets me use an X11 style XCompose file), and turning off GateKeeper completely (that's one thing I would never tell a naïve user how to do, or even that it is possible).
No claims that macOS is great for everybody, but I'm an experienced Unix user (my first Unix system was V7 on a PDP-11/45), and it works great for me.
[1] The one hack I needed was that you need a workaround to install MIT Scheme on Apple Silicon.
Anyone out there need a research paper on human behaviour related to preference of OS based on formative computing experiences? I'd be fascinated. :)
You can also always disable SIP and spelunk around if you want to. There's just far less of a hivemind for macOS tinkering and it's not as readily apparent to jump into.
But it does exist.