Selection is not working or locked

I found workaround:

  1. Selecting last object in Outliner
  2. Copying it to another Blender window
  3. Deleting broken one from Outliner in original file
  4. Pasting object back
  5. Moving to needed collection

If anyone can explain what’s wrong would be nice.

PS. I found topic from 2012 Can't Select Anything
But problem there wasn’t solved