"The bookcase has a lot of books."
Translation:La estantería tiene muchos libros.
Since "muchos" is used in the Spanish translation, it would seem more common for American English speakers to say, "The bookcase has "lots" of books." Dropping the "a" and adding the "s" to "lot" would be equal to "muchos." Mucho = a lot....Muchos = lots ...(no "a"). Either way would be acceptable in English but when translating to Spanish and "muchos" is required then "lots" would be better.
One of the definitions of librería in the DLE is:
Mueble con estantes para colocar libros.
SpanishDict says this is a European Spanish usage: https://www.spanishdict.com/translate/librer%C3%ADa
Note that library is one of the translations there, but in the "personal library" sense, not the public institution.
I don't think attempting to evaluate the naturalness of sentences in one language by comparing their literal translations in another is a very good strategy. Languages can express the same idea differently.
I suspect your comment is motivated by finding the English sentence here a little strange. I would agree. I think the Spanish sentence here is more natural than its literal translation.
I think it would be more natural to translate the Spanish here as "There are lots of books on the bookcase" (I have seen such translations accepted in the Portuguese course in analogous situations) or "The bookcase has lots of books in it." However, if the contributors used one of those, people would probably be confused as to why the Spanish translation wasn't literal.
It's far from a perfect measure, but Google results point toward "tiene" being more common than "contiene" in this context.
So 'en la estantería' means 'on the bookcase'? How, then, would you say, 'in the bookcase'? . . . I don't know how to use Google for checking word/phrase frequency, but I wonder whether the 'tiene' numbers are inflated by 'tiene que' or 'tiene' followed by an abstraction rather than by something concrete.
Sorry, I meant "in the bookcase" (although I suspect many English speakers would see "in the bookcase" and "on the bookcase" as largely overlapping in this context).
I searched for the whole sentences, so the uncertainty isn't about the context but how representative the Google results are of general usage.