PINs are already much "weaker" in that sense than best-practice passphrases should be. Yes, it's true that leaking the length of the PIN weakens it somewhat. Encouraging users to pick 4- or 6- decimal digits weakens it astronomically more. If a general-purpose password was that bad then it really would not matter in the least whether the length is leaked or not -- your password is cracked already. That's not the justification for why Microsoft leaks the length, but the point is Microsoft is not even slightly applying password best-practice to PINs.
The reason it's OK for Microsoft to leak the PIN length is the same as the reason it's OK for PINs to be so absurdly weak, when considered as passwords. It's used in a context where brute force attacks are defended differently. General-purpose passwords need to defend against brute force on leaked files containing password hashes. Obscuring the length is the least part of this, but it's there in the advice anyway. I think probably the general advice is designed such that protocols should give away nothing at all about the content of the password, no matter how little practical help that information really would be to the attacker.
Windows 11 PINs do not defend at all against brute force on leaked hashes, because their threat model says they don't need to. They defend against brute-force attempts to enter the PIN into the device by first requiring possession of the physical device to even start, then limiting the rate of guesses, and then eventually locking out the PIN and requiring a "proper" login, using whatever online security you have enabled (typically password and 2FA).
You can always re-assess general best practice in the context of a specific threat model, and this is what Microsoft has done. PINs AFAIK started with bank cards, where they are similarly weak and with similar justification (or actually with rather less justification prior to chip and PIN).
That said, my work laptop (which the IT department configured) doesn't leak the length of my PIN to someone who is guessing it. I have to hit "enter" at the end of it. So I think there must be some policy you can apply if you disagree with Microsoft's assessment, at least in enterprise contexts.