On Java edition, Allays don't follow the player as closely and tend to wander off a bit. This can also be applied to Noteblocks they're stationed at; the range in which they'll stay around it is sometimes so high, they won't go back to the Noteblock after their 30 second timer is up and wander away completely.
On Bedrock they stick to a more reasonable distance of their target, and are overall more responsive.
Note this is not a duplicate of
MC-249739 as this goes into their AI, not their movement speed. The videos below demonstrate this behavior.