Magnetoelastic coupling and the magnetization plateau in Ba3CoSb2O9