A parent is allowing their child to explore what their gender identity means to them
Exploring gender roles and identity is a great thing. Lying to your child about their biological sex (and expecting everyone else to collude in that) is not, for all the reasons outlined in the article linked above - you are encouraging the child to live a lie, and sooner or later that lie will collude with reality, whether that's in a swimming lesson, in their first romantic relationship, or when their health is destroyed by the side-effects of drug treatment or experimental surgery.
One of my dd's was very gender non-conforming. When she was about 5 she wanted a short haircut, and got frustrated by the fact that hairdressers can't seem to do anything more dramatic than a very short bob when they know a child is a girl. So at some point I got my scissors out and did a very short pixie cut, and she was absolutely thrilled. She mainly dressed in her older brother's cast-offs, so she did genuinely pass as a boy, and she really enjoyed playing with that - she loved people addressing her as 'lad', and enjoyed being able to go to the barbers and get a proper short back and sides. But what she liked about it was the ability to put on a new role, try out a new way of being in the world, and also being able to get one over the grownups in an 'I know something you don't know' kind of way. It was always grounded in the reality of her sex, but it enabled her to see that her sex didn't limit her to the gender roles that she saw around her.
At some point she decided to grow her hair out, even though she mainly carried on dressing in jeans and hoodies, and actually still does now -when she does put on a dress or heels for a particular occasion, it has the same sense of changing roles as wearing 'boys' clothes' did when she was small.
I do think that experimentation and boundary-breaking at a young age helped her to see that she didn't have to be limited by what other girls wore or did - and in fact she's gone on to do a very maths-based degree, which is another type of gender non-conforming.
None of those great outcomes (and she is a fabulous individual now, though I say so etc etc) would have been improved by lying to her that she could actually change sex.