As you can see in the video below there are 3 allays 2 have items and 1 does not, after i enter the portal you see that those allays with items teleport through the portal with me even though the door is clearly closed and they do not have access to the portal, and after i go back to the overworld you see them teleport back, but you see that the one with no items never teleports.
I have also tried this in different worlds it also happens there.
How to recreate:
You trap an allay in a box with no access to a nether portal and give it an item, after you go through any nearby nether portal you see that it appears on the nether even though it should not have access to a portal, after you go back to the overworld you can notice that it teleports back
Thank you for helping us improve Minecraft! We saved your files: