Do ants really dispose of their own dead, and how/why?
Eating the dead makes far more likely you will catch whatever killed them. They transport and dispose of the dead for the same reasons we do, to reduce disease vectors. They dispose of their garbage for much the same reason, in fact they often dispose of both in the same place even if they separate the two in distinct piles. Hygiene is very important is colonial insects because you are constantly surrounded by other ants which makes disease transfer very easy. Fungal infections are particularly problematic. They also have specialized toilet sites for the same reason. 

Note only some ants transport the dead outside, other put them is special chambers far from normal traffic and reserved for that purpose and refuse disposal. In either case they are moving them away from casual contact. 

Source 

Source 2