ファイル名の拡張子を変更する

Path.ChangeExtension()でファイル名の拡張子部分を変更できます。

string oldFilepath = @"test.txt";
string newFilepath = Path.ChangeExtension(oldFilepath, ".bak");

Console.WriteLine(newFilepath); # test.bak