Manchester United defender Luke Shaw has said he should not have played in their game against Luton Town in February when he injured his hamstring.