Machine learning (ML) is a subset of artificial intelligence (AI), which in turn is a field in the broader subject of data science. ML is focused on creating programs that learn by themselves to solve specific problems without having to write all the logic; we just need to give them lots of input. Trial and error is the main mechanism with the machine slowly learns how to achieve the right output to a problem.
The moment computers were created was the moment scientists asked themselves, "How can we make this machine think and act as a human?". That's why understanding how computers learn begins with understanding how humans see the world.
Think about it for a second: how do you think animals and humans learn to survive in the dangerous and confusing world we live in? By learning from others? Well, that's a valid learning system...