So you buy a nice two shelf bookcase but it’s wobbly and you know it won’t hold much. I’ve recently gotten one and my solution was to put L-brackets on it. After installing about 8 of these brackets at the cojoining parts of the shelving, it is now completely stable and ready for use.
The rigidity of a bookshelf is almost completely a function of how firmly its backboard is attached. The usual flat-pack kind just has a backboard made out of a thin piece of particle board, and over time the little brad nails they give you with it waller out the holes they’re in and/or back out slightly, and the entire thing gets progressively more wiggly. You can either add more nails or just replace them with short wood screws.
My contributory general advice to anyone living in their first home/apartment/whatever is to get a cordless drill and a set of bits for it. Not just drill bits for making holes, but also screwdriver tips. It is amazing the number of things you can find to use it on, and how much less annoyed you will be when some piece of furniture, fixture, or other gizmo requires removing or installing approximately 127,000 screws and you don’t have to do it by hand anymore.
Get a cordless drill/impact driver combo kit. It is amazing how much better impact drivers are at driving Phillips head screws without camming out and stripping their heads.