When my kids were in school, I was told they have homework because they don't have time to do the curriculum in the time frame and prepare for the state tests for federal funding. What I eventually learned is thst the homework is what they shoukd be learning in class, but they spend their class time preparing for the state federal testing.
Our education system is completely broken. We don't pay schools enough through state and federal taxes, and the schools need the funding the federal government awards through testing, so schools are spending the majority of their time trying to earn funds instead of teaching. The only real way for a child to get a well rounded education anymore is if you also teach them at home.
The sad part is, we did this to ourselves by constantly voting against schools and teachers. People don't want to pay the taxes, but they also don't want to know what their kids aren't learning.