BUG: Bug in selecting from a non-unique index with loc (GH5553)

closes #5553