You scenario is not what you think it is. I am 100% sure that your real value of totalCost
is actually 1.025
(one and twenty five thousandths), because this is the only value that will produce both the same results that you have given.
This can be seen with the following code:
double d = 1.025;
Console.WriteLine(string.Format(new System.Globalization.CultureInfo("it-IT"), "{0}",d));
//1,025
Console.WriteLine(string.Format(new System.Globalization.CultureInfo("it-IT"), "{0:0.0}",d));
//1,0
As you can see, both outputs match with yours. I would suggest you use a debugger to step through the code and see at which point the value is being changed. (perhaps you are dividing by 1000 somewhere along the line)
Direct Answer: There is no strange behaviour, the code is working exactly as expected.