> but are actually leased by their operators in Europe; there are five or six, I think, main ROSCOs —- rolling stock companies —- in the UK for example.
Nah, this is a UK absurdity because they UK decided to privatise their railways in the worst possible way - every single part (rail infrastructure, operations, rolling stock) was privatised in a local monopoly manner. The rolling stock owners could lease to multiple different operators, so there was some limited competition on that front (probably eviscerated by the need for the ROSCOs to have a profit margin, on top of the fact that there were 10 of them, which meant reduced economies of scale both at acquiring but also maintaining those trains).
They're currently trying to nationalise some parts, after already nationalising the infrastructure (because people died due to bad maintenance due to misaligned incentives - maintenance doesn't bring profits).
But other than that, rolling stock leasing mostly exists in freight.
https://en.wikipedia.org/wiki/Rolling_stock_company
> trains are actually not only mass produced (e.g. by Bombardier)
But yes, trains of all types are mass produced by companies such as Alstom (which were already massive and also bought Bomboardier's train arm), Siemens, Stadler, etc. They can be customised (size, features, etc.), but e.g. the Alstom Metropolis line of metro trains can be found all over the world.