Not sure I blame that on capitalism. A communist store/depot would also lock up in areas of high crime, if they even had products on the shelves to begin with.
Locked shelves were common in Russia when I was there almost 15 years ago.