I have been
working through Job for a little while now, and am currently working on sermon #49 (I'm currently in chapter 38).
Job does understand that there is life after death, although he does not have as full an understanding of it as we do, because of his early point in the history of redemption. It is remarkable that though this is likely the earliest book written in Scripture, Job does grapple with the concept of the resurrection.
Job is ultimately a book about Christ. Job suffered because he was God's finest servant, who feared God and turned from evil (true wisdom). However, once you get to chapter 3, it is obvious that Job is not sinless. He does not curse God, however he does complain against God and curses the day of his birth and night of his conception.
However, Christ is the sinless servant who suffers hell to redeem His people. He is ultimate wisdom, in Him are hidden all the treasures of wisdom and knowledge, and he suffered more than Job could ever imagine. Job suffered greatly in the body, but in Christ was freed from damnation.
It is clear from the text that Job is a historical figure. Though the familial and geographical designations are debated today regarding the main characters in the book, it is clear that the divinely inspired author included them to make clear to the readers who these men were, from where they came, and their familial relations.
The issue isn't why did Job suffer. The answer to that is easy, he suffered for God's glory, and ultimately God used the suffering for Job's good. Job's misconceptions (and those of his friends) were corrected by God during this trial. Job learned more of who God is and what it means to be his servant. When Job was Coram Deo, all anamosity, all questions, all discontentment fled away. He says in Job 42:3 "Therefore I have uttered what I did not understand, things too wonderful for me, which I did not know. "
That Job should suffer is no great mystery to us. Rather it is that Christ should suffer that is truly amazing!