I am quite an oldie, so I will write from my own, limited, experience of school absence. I also write as someone who never completed formal education and whose husband and children never completed formal education. We sort of 'did not make it through school'.
I went to secondary school in the early seventies. By the time I was nearly 15, I had developed a profound eating disorder and was sent to an adolescent unit. That, essentially, was the end of school for me. There was a little school at the unit, but I couldn't attend very often.
In the unit were quite a number of children with 'school phobia'. It was seen as a form of emotional disturbance. These children were different from the pupils who truanted. The truanting pupils would take days off here and there, but they were never permanently absent. I have no idea what the treatment for 'school phobia' was, only that it did involve medication (as everything did in those days).
My husband lost his father at 14, and only went back to school occasionally. I do not know if his absences were chased up, but I suspect there was some form of compassionate understanding if not compassionate leave. He received no outreach from the LA.
Therefore, nearly fifty years ago, there were pupils who were absent from school for reasons that were recognised as mental ill health. There would be, however, many pupils limping through the system, taking many days off or not being accounted for in those days.
My own children are both neurodivergent, and just did not make it through secondary school. My eldest has one to one support in every lesson and an EHCP, but still, he ended up in a CAMHS unit and never returned to school. My youngest received a small amount of home tuition from the LA (5 hours, and he hid away for half of that).
Therefore, I think nothing has fundamentally changed with respect to children not coping with school. I could say that the quite authoritarian and regimented school system (or the chaotic nightmare of poorer secondary schools) did not equip young people for the world outside, even half a century ago, and perhaps this is still the case. However, the majority of children do make it through school.
What may be different is the opportunities to catch up after school. My husband found an apprenticeship and eventually set up his own business. I found work, studied and entered a fulfilling career. My sons, however, are both in their early twenties and have not been able to take the first steps into a more independent life.