Answer
In the Name of Allah, Most Gracious, Most Merciful.
All praise and thanks are due to Allah, and peace and blessings be upon His Messenger.
In this fatwa:
The Sunnah is to separate individuals in their graves according to their gender unless there is a necessity.
Answering your question about burying men and women in the same grave, Dr. Jasser Auda, Professor and Al-Shatibi Chair of Maqasid Studies at the International Peace College South Africa, states:
The Sunnah is to bury men and women in different graves. However, if there is a necessity in a time of war or a time of civil unrest that is a different story. The Sunnah is to separate individuals in their graves according to their gender.
The issue of graves depends on the culture. There were two cultures at the time of Prophet Muhammad (peace be upon him); i.e. the culture of the people in Makkah and the culture of the people of Madinah
The culture in Makkah had open areas under the grounds where dead bodies were put. The culture in Madinah used to dig for every dead body by itself. The cultures differ but the separation of the dead bodies, unless there is a necessity, is the Sunnah of Prophet Muhammad.
Almighty Allah knows best.