Because it was the Jewish day of Preparation and since the tomb was near by, they laid Jesus there.
There was a need to hurry since the Sabbath day began at sunset, which was fast approaching by now. Thus the burial must be completed quickly, which is why they only partially prepared His body for burial (Luke 23:55-56). It is impossible to know how many people went to the tomb that late afternoon. One note is that Joseph and Nicodemus probably had servants with them to carry the body of Jesus and the hundred pounds of spices.
Luke 23:55-56 The women who had come with Jesus from Galilee followed Joseph and saw the tomb and how his body was laid in it. Then they went home and prepared spices and perfumes. But they rested on the Sabbath in obedience to the commandment.
There is an irony here that the chief priests, who were the religious leaders of Israel, did not keep the preparation day for the Passover and yet the disciples of Jesus, whom they had branded as dangerous heretics, were keeping it to the best of their abilities. Does this ever happen in the church today?
“Here is the Sun of righteousness set for awhile, to rise again in greater glory, and set no more.” (Matthew Henry)
Below is the prophecy of God’s suffering Messiah given through Isaiah.
Isaiah 52:13-53:12
See, my servant will act wisely; he will be raised and lifted up and highly exalted. Just as there were many who were appalled at him— his appearance was so disfigured beyond that of any man and his form marred beyond human likeness—so will he sprinkle many nations, and kings will shut their mouths because of him. For what they were not told, they will see, and what they have not heard, they will understand.
Who has believed our message and to whom has the arm of the LORD been revealed? He grew up before him like a tender shoot, and like a root out of dry ground. He had no beauty or majesty to attract us to him, nothing in his appearance that we should desire him. He was despised and rejected by men, a man of sorrows, and familiar with suffering. Like one from whom men hide their faces he was despised, and we esteemed him not.
Surely he took up our infirmities and carried our sorrows, yet we considered him stricken by God, smitten by him, and afflicted. But he was pierced for our transgressions, he was crushed for our iniquities; the punishment that brought us peace was upon him, and by his wounds we are healed. We all, like sheep, have gone astray, each of us has turned to his own way; and the LORD has laid on him the iniquity of us all. He was oppressed and afflicted, yet he did not open his mouth; he was led like a lamb to the slaughter, and as a sheep before her shearers is silent, so he did not open his mouth. By oppression and judgment he was taken away. And who can speak of his descendants? For he was cut off from the land of the living; for the transgression of my people he was stricken. He was assigned a grave with the wicked, and with the rich in his death, though he had done no violence, nor was any deceit in his mouth.
Yet it was the LORD’s will to crush him and cause him to suffer, and though the LORD makes his life a guilt offering, he will see his offspring and prolong his days, and the will of the LORD will prosper in his hand. After the suffering of his soul, he will see the light of life and be satisfied; by his knowledge my righteous servant will justify many, and he will bear their iniquities. Therefore I will give him a portion among the great, and he will divide the spoils with the strong, because he poured out his life unto death, and was numbered with the transgressors. For he bore the sin of many, and made intercession for the transgressors.