I had a little dog that did this when first adopted her. In her case I think it was more of “what’s over here? Now what’s over here? Oh, something interesting on the other side…” I had to make things on one side of me accessible as I slowed down to let her sniff. Things on the other side we walked past quickly. She figured out it was better to stay on one side.
As far as herding or claiming, if you walk shoulders up and with confidence and purpose, she shouldn’t feel the need to do either. Making a barrier between you and strangers, that might be the case. I’d recommend showing her that you would rather have her sitting by your side. She really doesn’t need to protect you from friendly strangers. Just my two cents.