The answer is, here natural selection played no role at all. Here, evolution occurred due to artificial selection. Due to human interference. Humans practiced selective breeding of chickens. Thousands of years ago, a person might have noticed a chicken laying more eggs. Selectively, that chicken was bred to have an offspring that laid even more eggs. It was done to the next generation too. This kept on repeating again and again. Artificial selection was carried out by humans which led to the present-day situation where a chicken lays 200-300 eggs a year.
Many people will find this human intervention unnatural. But humans do this artificial selection in cows and buffaloes as well. The cow that gives more milk is artificially bred by farmers. Or some other hereditary traits that are more beneficial to farmers are selectively bred so that it is more prominent in future generations.
Now, hearing this, the vegans would say, that this is a reason why we should not consume milk. Because humans keep interfering everywhere. Humans have bred these animals for their own benefit.
But the thing is, friends, humans have not only bred animals like this but have also bred trees and plants by artificial selection. Broccoli, cauliflower, cabbage all these vegetables have evolved from wild mustard plants after thousands of years of artificial selection.