Favored and holy are those who have a share in the first resurrection. The second death has no power over them, but they will be priests of God and of Christ, and will rule with him for one thousand years.
When the thousand years are over, Satan will be released from his prison.
References for Revelation 20:7
He will go out to deceive the nations that are at the four corners of the earth—Gog and Magog. He will gather them for battle. Their number is like the sand of the sea.
They came up across the whole earth and surrounded the saints' camp, the city that God loves. But fire came down from heaven and consumed them.
Then the devil, who had deceived them, was thrown into the lake of fire and sulfur, where the beast and the false prophet also were. There painful suffering will be inflicted upon them day and night, forever and always.
Then I saw a great white throne and the one who is seated on it. Before his face both earth and heaven fled away, and no place was found for them.
References for Revelation 20:11
I saw the dead, the great and the small, standing before the throne, and scrolls were opened. Another scroll was opened too; this is the scroll of life. And the dead were judged on the basis of what was written in the scrolls about what they had done.
The sea gave up the dead that were in it, and Death and the Grave gave up the dead that were in them, and people were judged by what they had done.
Then Death and the Grave were thrown into the fiery lake. This, the fiery lake, is the second death.
Then anyone whose name wasn't found written in the scroll of life was thrown into the fiery lake.