What is the difference between the first and second resurrection in the book of Revelation? I want to understand What is the meaning of first resurrection and 
second resurrection.

Revelation 20:5 KJV


  But the rest of the dead lived not again until the thousand years were finished. This is the first resurrection.


Revelation 2:11 KJV


  He that hath an ear, let him hear what the Spirit saith unto the churches; He that overcometh shall not be hurt of the second death.


Revelation 20:12-13 KJV


  And I saw the dead, small and great, stand before God; and the books were opened: and another book was opened, which is the book of life: and the dead were judged out of those things which were written in the books, according to their works. And the sea gave up the dead which were in it; and death and hell delivered up the dead which were in them: and they were judged every man according to their works. 


How is the first resurrection different from the second one?
The two events only differ on two points:

Who is raised.
When they are raised.

Both parties are actually judged equally, and we assume the method of the raising is the same.
The First Resurrection takes place at Christ's coming and consists of the Righteous Christians only.

For the Lord himself shall descend from heaven with a shout, with the voice of the archangel, and with the trump of God: and the dead in Christ shall rise first:
Then we which are alive and remain shall be caught up together with them in the clouds, to meet the Lord in the air: and so shall we ever be with the Lord.
1 Thessalonian 4:16-17

The First and Second Resurrection and the Final Judgement of all souls is detailed further in Rev. 20.

4 And I saw thrones, and they sat upon them, and judgment was given unto them: and I saw the souls of them that were beheaded for the witness of Jesus, and for the word of God, and which had not worshipped the beast, neither his image, neither had received his mark upon their foreheads, or in their hands; and they lived and reigned with Christ a thousand years. [This is who takes part in the First Resurrection. They are those that are in Christ; they are Christians; they are the righteous]
5 But the rest of the dead lived not again until the thousand years were finished. This is the first resurrection. [If there is a 1st resurrection there must be at least a second]

It will be 1000 years after the resurrection of the righteous that the remaining souls, the wicked, will be resurrected for Judgement.

12 And I saw the dead, small and great, stand before God [This is the only place that makes sense for the second resurrection, and we already know from verse 5 that it is 1000 years after the First Resurrection]; and the books were opened: and another book was opened, which is the book of life: and the dead were judged out of those things which were written in the books, according to their works. [After being raised they are judged]
13 And the sea gave up the dead which were in it; and death and hell delivered up the dead which were in them: and they were judged every man according to their works. [Every dead person will be raised at some point]

These verses (the whole book, even) are very poetical, but these verses together show that the wicked dead are indeed resurrected, just as the righteous 1000 years earlier.
Summary
The First Resurrection consists of the Righteous Christians, which will be raised at the end of days upon Christ's coming (1 Thessalonians 4:16-17).
The Second Resurrection will follow 1000 years later (which may be a non-literal 1000 years) and will consist of all the remaining dead (the wicked) (Revelation 20:5).