Myriapod robot with variable body-axis flexibility