Then I saw thrones, and people seated on them who were given authority to judge. [I] also [saw] the souls of those who had been beheaded because of their testimony about Jesus and because of God's word, who had not worshiped the beast or his image, and who had not accepted the mark on their foreheads or their hands. They came to life and reigned with the Messiah for 1,000 years.
References for Revelation 20:4
The rest of the dead did not come to life until the 1,000 years were completed. This is the first resurrection.
Blessed and holy is the one who shares in the first resurrection! The second death has no power over these, but they will be priests of God and the Messiah, and they will reign with Him for 1,000 years.
References for Revelation 20:6