Never mind, i think i figure it out. The word "of" can mean many things, one defintion from Longman's Dictionary states:
"used to say what a story, some news is about, or what a picture, map etc shows"
In my examples "book of stories" that is how it is being used. They are saying the book talks about/gives/has the contents of stories. Same with "list of groceries", it is a list expressing, show or listing groceries.
Guess i read too deeply. THanks