Gee, I have 2 of them (see my signature pic, a HDCC3 and an HDC. Mine are 2002 and 2004 and I haven't had any muffler corrosion what so ever. Strange.
If I were you, I'd forget about the muffler and get a pipe bent to fit. I has a turbo and it won't be loud so forego the muff entirely.
You need to do a COMPLETE filter change, the 2 hydraulic filters under the right rear wheel, the spin on fuel filter, the sediment filter in the clear bowl (in front of the spin on filter), the oil filter (on the right lower side of the engine) as well as the primary air filter inside the air filter housing.
I would also change the anti freeze. The M9's have no radiator drain, you have to release the lower rad hose clamp and drain it that way.
Possibly change the gear case oil (depending on how it looks, dirty or not) and the front axle lube (if it's a FWA unit). Don't use cheap Tractor supply hydraulic oil either, Kubota's don't like that junk and it will cause issues down the road, use something compatible with Kubota's spec for UDT. Front axle can also have it inside but I use 85-140 gear oil myself.
In the crankcase I use Shell Rotella T6 but that is your call as any diesel rated oil will do. I have over 6000 hours on one and 4000 hours on the other and no issues (other than routine stuff) on either and I farm with mine. Bought them both new and neither are for sale either.
You can find Kubota shop manuals and owners manuals (if you don't have them) online at Kubotabooks
Here are the 2 brothers...