I work with adults with learning disabilities, and an adult woman with a mental age of 9 (we aren't allowed to phrase it like that any more, officially) is not the same as an actual 9 year old.
It does say 6-9 in the article, not 9. It's not actually, of course, possible to be exact to the year.
The mental capacity of a 6-9 year old usually means moderate learning disabilities. In the end, although we're also not supposed to use IQ, that is a measure of IQ not holistic age equivalence. She probably has an IQ under 50.
She might be far more mature than you're average 9 year old, or far less mature than your average 6 year old.
Normally she'd be able to consent to sex, because she isn't 9, she's in her 20s. She has the same physical wants/ needs/ desires as anyone in their 20s (which, of course, could mean no interest in sex at all or a great interest, but that's unrelated to IQ).
Of course she's also hugely vulnerable to abuse, and that's one of the problems - she had adult rights, up to a point, but they conflict with the responsibility of her care giver and society to protect her from abuse of all kinds. It sounds as though in this case she does not have a partner, as how she became pregnant is being investigated.
I don't think it was necessarily right to make her have an abortion but her case will be so incredibly complicated the article can't possibly explain the intricacies. Most of them are confidential.
The article hints strongly that she'd be an actual danger to her baby due to her mood disorder, so she probably has significant comorbid mental illness, not "only" an intellectual disability. The article hints that it would be impossible for her to live with the baby even if her mother did the care.
It's very likely she's on psychiatric medication incompatible with a healthy pregnancy, or has had to come off such medication while pregnant.