Ability/need isn't a scalar quantity and real students don't distribute themselves in a way that can be described by a couple of parameters.
I don't know what the answers are either but I think we need to be very explicit about any assumptions underpinning proposed models. I also agree with the 'bottom up' part of the gf comment.
Now, what discrete 'styles of instruction' are there do you think?
Is this no longer the case? This was 3rd-6th grade, I don't remember much before those grades.
Of course, there are more axes of student variation than schools can segregate on without having a single educator dedicated full time to each individual student, and there are other factors working against such segregation -- it imposes additional curriculum costs costs, and administrative costs which are politically unpopular, and it creates decision points which parents frequently disagree with, which leads to conflict and additional costs on top of those basically necessary to manage the segregation.
So, in my mind, your question is mainly asking if increased amounts of differentiated instruction could benefit elementary school students. I've definitely heard way more about the difficulty of dealing with poorly behaved students than the difficulty of dealing with well-behaved, but low achieving students. That suggests segregating not along ability lines but rather along behavior/self-control lines.
If you run with that idea, and keep class sizes the same for well-behaved children and poorly behaved children, the "good" kids would probably benefit, but the "bad" classrooms would be completely out of control; in effect you would be completely writing those kids off at a very early age. Depending on the capability of the teachers and the difficulty of the student population, I personally think that might actually be a socially optimal use of resources. However, that is a very controversial opinion, and there are a whole lot of people who would not agree with me on that (and most of my teacher friends are among them).
If you go to very large classes for "good" kids, and very small classes for "bad" kids (say ~50 kids vs ~10), you have a different set of problems. A class of 50 8 year olds can get pretty hard to control, even if they're well-behaved 8 year olds. Plus, most schools don't have the facilities to accommodate classes that size. You can bet parents aren't going to be that pleased to have their kids in huge classes. And even if more individual attention is what the "bad" kids need, you still have the problem that you've labeled the bad kids as bad; they'll figure it out and it will probably have adverse affects on those kids' development. That may offset any benefit you're getting from the smaller class size in the "bad" population.
So I don't think it's actually the slam dunk it might seem from a casual analysis.
Schools (and teachers) do account for this as much as they are able to, but having 30 children in the same classroom is more cost-effective than having real provision for individuals.
The reality of it is that we group kids by age and geolocation and put them under the same teacher. It works out mostly ok, improving that will be a hard problem.
Even defining an improvement is not trivial as well. While you ask if students can be grouped by ability, some schools prefer to split these students up, with the thinking that there is more to be gained by having children helping each other out in the same room.
Lower functioning students are provided with much more 'hands on' teaching situations.
I don't know how effective separating student more would be- one could argue that at a certain point it might harm the students because of the lack of socialization. A selection bias of social awkwardness, if you will.