I have a 10-year-old daughter in fifth grade who has had the same best friend since first grade. Her best friend has now made a new best friend and ignores my daughter. She has tried to be friends with other groups, but doesn't feel comfortable. She has now been playing by herself at recess for the last six months.
Once children reach middle level, friendships change rapidly as children develop their social and personal skills. It appears your daughter has been hurt deeply and that she doesn't have enough confidence to continue trying to make friends. I strongly urge you to get involved right away. Playing alone at recess for six months indicates a very serious problem.
Talk with the school counselor about the situation. Ask if the counseling department offers friendship groups or if the counselor has ideas and ways of engaging your daughter with others. Individual counseling sessions with the school counselor might also be helpful