Data gets orphaned when grouped into a collection (2.8+)
This is not classified as a bug, but rather a usability issue.
Anyone wanting more details can read the developer discussion here.
I hesitate to quote excerpts from that discussion in this answer, since the design will almost certainly evolve and change. But there seems to be some disagreement about how some of the functionality from previous versions of Blender should be carried over in 2.8 onward with regard to collections.
For now, users are better off using the M key when adding objects to a new collection.
More information about creating collections and adding objects to them can be found in the Blender Manual.