This is a bit of physics that I will try to make comprehensible.
There are several concepts that play into this, I will list them one at a time first, then you can combine them to see how it all works especially if your home is two floors, however we see this problem in single story homes as well... it is a very common problem.
1. The upper floor water pressure will be less than the first floor water pressure because of the 10feet of extra lift required.. thats 2.3 feet per pounds per square inch less, or about 4 psi less than pressure than the down stairs shower.
2. The cold water pressure will be higher than the hot water pressure because the hot water has to force its way through the heat exchanger, you can subtract 7 to 10 psi for that pressure loss,20 pounds if the heat exchanger is fouled with water scale. You can subtract an addition 2 or maybe 3 psi for the longer tubing run tothe upstairs, especially if it was fit with border line too small tubing.
3. The shower head offers more resistance to water flow, the higher the flow through the shower head, the greater the pressure loss. lets say as a guess, for this purpose, 5 psi pressure drop at the shower head... you can subtract that pressure drop at the shower head from the net hot water pressure.
4. Some cities or water well systems operate at higher pressure than others.. lets say for this example 40 psig going into the water heater.
5. The cold water flow through the mixing valve at the shower head will tend to displace the lower pressure hot water....so that the hot water flow through the shower will often be less than the 0.5 to 0.7 GPM required to keep the flow switch open. all together you migh thave 40 psi cold water an only 20 or 30 psi hot water pressure. That's the nexus of the problem.
So the boiler will shut off as the flow switch turns off the burner if you are running your shower at lower flow rates .....or if you have a water saver flow restricter in the shower head. That can even force the cold water back against the hot water port enough to stop the hot water flow entirely (shutting off the flow switch).
The cure is to run the shower at higher water flows, or remove the flow restricter in the shower head, or possibly take warmer showers, all with the intention to keep the flow switch in the boiler from shutting off the gas valve when flow rates through the boiler heat exchanger drop below ½ or ¾ gallons per minute.
Beyond that the hot water pressure will drop as you are taking a shower when someone else turns on a hot water tap... the boiler will keep firing, but the hot water pressure will drop significantly allowing the higher cold water pressure to overwhelm the hot water pressure and stop the hot water flow entirely..... the variable here is the diameter and length of the water tubing.
This will all be worse at the upstairs shower than the down stairs shower because water pressure to the upstairs is lost in pipe risers. You loose 1 psi per every 2.3 feet of rise.
Youmay want to leave the flow restricter in the downstairs shower for that reason.
Other issues, as the heat exchanger for the domestic hot water builds up with water scale...the pressure drop on the hot water side increases linearly... to maybe 20 psi pressure drop instead of 10 psi... making it even easier for the cold water supply pressure to overcome the hot water pressure in a mixing valve type faucet. (single handle or knob and one spout or shower head).
Look all that over please, let me know if it makes any sense in your situation, we can go from there without any time limit.
We are on the honor system here. Please remember to rate my service before you leave today, the company only pays me if you rate my work. It is how I earn a living, and does not increase your charges.
If you need anything else, just let me know. You can continue asking follow-up questions at no additional cost.