A six-year-old boy was injured outside a shopping centre after being hit by an e-scooter rider on the pavement during half term.