Natural Selection is the core mechanism of Evolution.
If traits vary, are heritable, and affect survival/reproduction, then over generations those traits shift in frequency.
Selection is not goal-directed. It is just differential success under real-world constraints.