The water heated in a metal boiler is kept mid-way, to create enough space for steam. The steam is used to heat milk and froth it. My question is, how does the level of water -- higher, lower, middle vertically inside the boiler -- affect the quality of steam?
Boiler water level has a significant effect on steam capacity and temperature stability. It may also impact steam quality.
There are three steam characteristics to look at: the amount of steam available, steam power, which is pressure but it's easier to visualize this as velocity and quality. High quality steam should be dry and saturated, not wet. Within the safe (design) operating range of water level for your boiler, a lower water level means that there is more headspace or space for the steam. This means that you will have a larger supply of steam, higher quality (drier) steam and better temperature stability because it's easier to heat a volume of steam than the same physical volume of water.
A higher water level will reduce the effective amount of steam available and tend to create wet steam as more water gets entrained into the steam. Conversely if your machine sees heavy use for espresso but not steam, you may benefit from a somewhat higher water level which favours water temperature stability.
The intended water level serves several masters as a espresso machine requires water and steam and of course safety, cost, stability and steam quality in an usable balance. On a single boiler machine you can't really increase the boiler pressure to increase steam power because it would make the machine run too hot for quality espresso extraction. In general, it is desirable to operate single boiler machines on the lower end of the safe water level range for better steaming ability.
However if you have a consumer machine with an inadequately small boiler you may find that lower water levels produce an apparently anemic steam jet. The proper fix for this would be a larger, more capable boiler but pragmatically a higher water level will then produce a more usable steam flow because the entrained water in wet steam has more inertia or force at the expense of less steam capacity and lower quality steam. Or to put it another way in a machine that has too small of a boiler you may need to keep the water level higher to get enough steam power but it will also degrade the steam quality and will make texturing milk more challenging.