The expressions “out of the graves [tombs]” and “out of the tomb” have different shades of meaning in the New Testament,

The expression, “out of the tomb”, is twice used in the singular. John 12:17 (NKJV), “…He called Lazarus out of his tomb and raised him from the dead…” It’s used about  Jesus when Mary of Magdala surmised that “they have taken away the Lord out of the tomb.” John 20:2.  In each case it is of someone coming out from inside a specific tomb. 

Matthew 8:28 speaks in the plural of two demoniacs “coming forth out of the tombs.” Mark 5:2 speaks similarly of a man with an unclean spirit. Clearly, none of these three was dead; so the expression evidently merely means these were in a cemetery, and not necessarily inside a tomb (empty or not). Luke 8:27 speaks of a demoniac who “abode … in the tombs,” when he also was not dead. 

It is also in the plural, later in Matthew 27:52-53 (WEB), “And the graves were opened, and many bodies of saints who slept, arose, and came out of the graves after his resurrection, and went into the holy city, and appeared to many.”

Some questions about this seemingly mysterious account need be resolved: 

* Is any group called “saints” other than Jesus Christ and his church? 

* At the end of verse 52 the Greek word primarily means “awaken, arouse” (Liddell & Scott). Does it mean awaken from sleep or from death in this context? 

* It says, “they came forth … after his resurrection,” not “after their resurrection(s).” 

The text may be easier to understand than it seems at first glance. The “saints” need only come out of a cemetery. The “saints” usually means the (faithful) church; so why not the apostles here? They had been so tired after the Last Supper that they could not watch one hour without falling asleep, and it is here said that they had fallen asleep; so the earthquake awakened them. They remained fugitives in the city of Jerusalem until after Jesus was resurrected.