In my locale, riding on the sidewalk is not illegal. I think it's situational. Do whatever's safer, more considerate, etc.
For the rental bikes, it may depend on
who is riding the bikes, and the shop owner may have a sense of this. I'd expect a streetwise cyclist to make their own call -- perhaps after they're out of sight of the shop.