I was playing on a creative/survival world testing a mod and when I went to add an effect to myself I found an odd string in the possible entities. I investigated more and found that only an entity close to you can be referenced this way, and only sometimes, but this could also be wrong.
You mean the UUID suggested in auto-complete in commands? It only suggests the looked at mob's UUID. Also, entities need to be loaded to be targetted; go too far away and they unload.
There's no bug here.
Also, issues with modded versions are not accepted here.