What's the point of PhD theses if nobody reads them? At best, the PhD thesis is read by:


The author
The examiners
The supervisor
The author's parents
The author's roommate / spouse / fellow students in research group


Or less than 10 people in total. What, then, is the point of writing it? Writing a complete PhD thesis is a time-consuming process, and that time could easily have gone into taking more courses, doing more research, supervising more students, and so on. Of course the PhD student has no choice but to write one, because the programme typically requires it. However that still begs the question as to why the programme requires it in the first place. if the thesis is so useless that so few people read it, what's the point of demanding a thesis as a prerequisite for graduation?

Somewhat related: What is the point of a PhD thesis whose content already exists in published papers? Still, even if there are more readers because a thesis provides a gentle introduction to the field, it seems more sensible to me to just write a monograph and leave out the thesis.
For simplicity, I am going to let your premise that (virtually) nobody reads a PhD thesis stand, even though that's debatable and also a bit field-dependent. There are still a number of reasons for it to exist:


It's arguably more of a "writing to learn" task anyway. Students don't produce theses for the sake of the thesis, but to learn how to do research and write it up properly in a long, coherent book. Even if no single person outside the committee reads the thesis ever, it was still a good learning experience for the student.
There is a lot of history around the concept of a doctoral program requiring developing in new thesis (in the original meaning of the word), writing it down in a book (the dissertation), and defending this new thesis against the local learned community. Even though nowadays many fields don't communicate new research ideas through long books anymore, there is still enough historical appeal to the idea that few programs want to get out of it entirely. The entire process of writing and defending the dissertation also has some appeal as a significant milestone event, which nicely demarks the end of an era for the student - he is no longer a student, but a complete member of the academic community.
In many countries there is a legal angle to this. At least in Europe, a PhD program is usually legally defined to conclude with the production of a doctoral dissertation of some kind. 
In the age of "stapler theses" (which consist of a synopsis and a collection of previously published papers in verbatim), the entire affair is fairly low-cost anyway. My last students rarely spent longer than 2 or 3 months on the actual "thesis writing".