Items jump to the next available air space above where they were mined.
Steps to reproduce:
1. Dig down a bit in survival. Only a few layers above the surface.
2. Start digging.
3. After about five minutes, go up to the surface and look at the items that have jumped up.
I think this is a duplicate of MC-47650, though I think your title and description are good.