From what I understand the biggest causes of poor school performance are things you can’t fix in a classroom. There is a distinct causal relationship between poor school performance and issues like poverty, broken homes, etc. If you’re a kid living in a poor household, your single mother has to work long hours to make ends meet, or you’re dealing with family issues at home, your schoolwork will obviously suffer.
It shouldn’t surprise anyone that the poorest states in the US also have the worst educational performance. And it shouldn’t surprise anyone that the US, which has more income inequality and higher poverty than almost every other first world country, would also have worse school performance despite spending more money than they do.