That is absolutely not true. At very selective schools, students are evaluated on taking the most rigorous curriculum that their school offers. If the school does not offer a slew of AP courses, the student is not going to be penalized (I speak to this from both personal and professional experience- where I know and speak with a lot of AOs).
If your school offers a lot of AP courses, and a kid takes one or two, yes it will raise a red flag. If a school offers only 4 (my daughter’s school only offered AP English Junior/senior year and AP calc or AP stat) that it what they will be evaluated on. It did not hurt her as she was admitted to every single school she applied to (Ivies and top LACs)
Most highly selective schools don’t look at weighted gpas because there is already an expectation that the student is taking the most challenging courses the school offers and is doing well.
Feildston school did away with AP classes almost 13 years ago and it did not hurt their college admissions
https://www.ecfs.org/uploaded/ECFS_College_Destinations_2016.pdf