Try starting from a blank slate Windows machine and making a commitment to only changing settings via PowerShell, and ideally only declaring them using DSC. You'll soon discover settings where the best you can do is snapshot the registry, change a setting in the GUI, snapshot the registry again, then take a diff so you can write the registry change into your PowerShell automation. If you're on a corporate machine, you'll also likely find many corners of PowerShell that you need closed off to you, anyway.
At the end of the day, Windows is not friendly to automation because it's not CLI-first (not culturally and not technically).