Those trains are operated by the SBB until Domodossola, where an Italian crew takes over. So they are Swiss till then, and Italian after.
If you buy a ticket for the EC 39 from Domodossola (it leaves there at 16:17) you can indeed just board that train in Geneva, and stay on it till Milano.
Or you can detrain in Domodossola, and take a later regional train. In that case you will save a few Euros, and add about an hour travel time. Its up to you.