It’s awful for stretching, it doesn’t isolate muscles very well and strains joints. If it was good for stretching, you’d see NFL and MLB players doing it on the field before their games. It’s a ridiculous, roundabout way to do something that science has figured out can be done much quicker and easier, with less risk to the body.
It’s just a vain feel good activity. Yoga practitioners talk all about their “practice” and improving themselves through their “practice”. You’ll hear yoga studios say stuff like “don’t go to church, just do yoga!”. There’s a bunch of pride wrapped up in getting the poses right, but this doesn’t benefit your body, it just lets you one-up on other people because your pose is “more correct”.