hi, I think in the 19th century, it was considered normal to keep cows tied in stalls in the city .
Today, we tend to keep milk cows in sheds on farms over the winter and turn them out to graze in the summer as it is cheaper to let them eat grass. In the winter they eat expensive food which has to be conserved over the summer, and also the manure has to be carried away and dealt with.
Back then, before refrigeration, there was a premium on fresh milk in town so it paid to bring in feed, carry away the manure, and pay milk maids to milk them. I think they stayed in their stalls all year round in street cowhouses.
The economics changed with the arrival of railways and refrigeration. Suddenly it became possible to produce cheaper grass fed milk miles from the city and get it to the town in an hour or two. The Milk Marketing board of 1933 ensured that transport costs were averaged out no matter where the milk was produced, so producers in remote areas were no longer at a disadvantage.
Cows would have been milked by hand, certainly up to the 1920s.
Fred