When Jesus resurrected Lazarus from the dead, he reported to be asleep for 4 days and he didn't go to purgatory. Does that mean the soul sleeps after death until the day of resurrection?
It's called in a state of Barzakh (Purgatory). You can check it up. The literal meaning of 'Barzakh' is a veil or a barrier that stands between two things and which does not allow the two to meet like to oceans that do not mix with an invisible barrier. The soul doesn't sleep, the soul simply is questioned by the Angels Munkar & Nakir (Alai). They'll be halfway between reward and punishments, for example, if someone did not pray on time, he'll be punished accordingly. If he recited Sura Al Mulk after every Mahrib prayer, he'll be rewarded with having eternal light in his grave and so on. There are many Ahadith accompany this state with many informations. Briefly the prophet (pbuh) said,
Then two [severe] angels shall come and [terrify him and] sit him up next to them and shall ask him: "Who is your Lord?". He shall reply "My Lord is Allah". Then they shall ask him: "What is your religion?". He shall answer them: "My religion is Islam". Then they shall ask him "Who is this man who was sent among you?". He will reply "He is the Messenger of Allah (SAWS) peace be upon him". Then they shall ask him "What have you done?". He shall reply: "I read the book of Allah, then I believed in it and accepted it". [The angel will terrify him and ask him "who is your Lord?", "what is your religion?" "who is your prophet?", and this will be the last trial on earth for the believer, it is then when Allah says : "Allah will establish in strength those who believe with the word that stands firm in this world", so he will answer my Lord is Allah, my religion is Islam and my Prophet is Mohammad salla Allahu alaihi wa sallam. Then a caller will call from the sky: "My slave has spoken the truth, so spread out for him from the heaven, and clothe him from the heaven, and open a door for him from the heaven (within his grave)", so it's goodness and its smell will come unto him, then his grave will be expanded for him as far as he can see. As a Hadith tells us, time passes quickly for a believer, as long as it takes to pray two quick Rak'as.
For a non-believer: Then two harsh severe and fearsome angels shall come and [terrify him and] sit him up and shall ask him: "Who is your Lord?". He shall reply "Huh?, Huh (this is an expression of sorrow), I don't know". Then they shall ask him: "What is your religion?". He shall answer them: "Huh?, Huh?, I don't know". Then they shall ask him "Who is this man who was sent among you?". He will reply "Huh?, Huh?, I don't know [I heard people saying that!]". He (the Prophet salla Allahu alaihi wa sallam) said "And then will be said to him don't ever know and don't ever recite!"]. Then a caller will call from the sky: "My slave has spoken falsely, so spread out for him from the hell fire, and open a door for him from the hell fire (within his grave)", so its heat and hot wind will come unto him, then his grave will be contracted upon him until his limbs are caught up among one another. Then a man will come to him. His face will be ugly, and his clothes will be ugly, and his smell will be vile. Then he shall say unto him: I bring you tidings of that which will harm you. This is the day that you were promised (70:44). Then he will say [and you, may Allah give you bad tiding] "who are you?, for your face is the face of someone who comes with evil". He shall reply: "I am your evil deeds [by Allah, I did not know of you but that you were quick to the disobedience of Allah and slow to His obedience, so may Allah reward you bad, and then will be assigned to him a blind, deaf and mute person who holds in his hand a hammer, if a mountain is hit with it, it would disintegrate, and he will beat him with it until he becomes dust, and then Allah will render him to his initial form, and he will beat him again, and he (the wicked) will cry of sorrow and pain a cry that will be heard by all creatures except humans and jinn, and a door of hell will be opened unto him within his grave and will spread out for him sheets of hell fire]". Then he shall say: "My Lord do not bring the hour".
I'm not a scholar, I could be wrong. If you find any mistakes in what I've answered, please let me know so I can remove the comment or edit it out.