Safety reasons: This is to prevent the book case from falling over in case of an earthquake, or if children pull on it, or if someone bumps into it.
If you’re in a low earthquake hazard zone (research the earthquake risks for your location), and won’t have kids, or alcohol-fueled parties, you can skip the bracing.
Put the heavier stuff on the bottom of the book case, and don’t make a habit of keeping lit green energy candles on it. (it’s common sense, I think.) Or larger potted plants, for that matter.
You could fix the bookcase to the wall if you know how to repair the hole before you move out. But you’ll need permission from your landlord/ rental agency for that.
Or pick a combination bookcase/desk that isn’t likely to fall over.