A bookshelf is often a part of a bookcase which is a collection of shelves.  Bookshelves also are shelves on a wall that hold books.