When bees wander far from their nest or hive, they get lost and don't remember it.
This can be fixed by adding bee memory of the coordinates of their nest or hive they last entered.
Related issues
Attachments
Comments

[media]

Are you sure the bee is actually lost? This issue was fixed in 19w45a as per MC-159803.
Also, does MC-166980 describe your issue?

Yes, they got lost after they pollinated a flower

So does MC-166980 describe your issue?

Yes