In my experience, managers don't have to be hands-on, but they need to be able to recognize people with talent and unblock them do their jobs, to be able to spot process improvements, including channelling the AI hype to productive outcomes, and to be a steadying influence in a crisis (without adding noise). If a manager doesn't have technical ability, its impossible for them to do those things.
Everything but the AI bit are on my list of manager qualities too, but the best managers I've had weren't active programmers, and one had zero coding background.
Knowing what you don't know and knowing how to get qualified information from people around you makes up for a lot of not having a programming background.
If anything, the managers with technical backgrounds who weren't active programmers tended to significantly underestimate the difficulty of doing something because back in their day, things were different or some such nonsense.