The three friends are not unbelievers. They are believers who have angered God by their folly.
Fortunately for them, God is not the severe judge that they have made him out to be! He offers them grace and forgiveness.
However, God’s grace is costly. False doctrine is a grievous sin in his eyes. This is clear from the big sacrifice that the friends are told to bring: seven bulls and seven rams. Moreover, God will not accept their sacrifice unless Job prays for them.
8 Now therefore take seven bulls and seven rams and go to my servant Job and offer up a burnt offering for yourselves. And my servant Job shall pray for you, for I will accept his prayer not to deal with you according to your folly. For you have not spoken of me what is right, as my servant Job has.”