I don't know if an actual mileage is specified any more. Many manufacturers now consider transmission lubricant to be a "for life" item - not a point of view I subscribe to! Some are even deleting a drain plug! (insanity in my view!) Of course modern synthetic lubricants are vastly superior to the old mineral based stuff and will last much much longer but as a gearbox runs it imposes extreme forces - especially shear forces - on it's lubricant which will degrade it. Also very small metal particles will accumulate, from bearings, synchros, selector forks and gear faces etc, which will tend to circulate with the oil - which is not good. Draining the old oil, after a nice long run when it's got really nice and hot, will remove most of this debris with the old oil. If you've ever drained and refilled the oil on a "tranny" that's done maybe 100,000 miles or more and then refilled with new you'll know it's surprising how much more quietly it runs and silky smooth the gear change becomes - assuming of course that it's in generally good order otherwise - new oil is not going to miraculously mend a knackered old box!
Only one of the 6 cars in our extended family covers in excess of 10,000 miles a year so the 5 which don't I
service once a year and I change transmission oils at 5 years or 50,000 miles. (but look at your hand book or ask a main
dealer what they recommend just in case your's is unusual). I'm talking only of manual gearboxes here. Automatics need changed too but often you should change filters on hydraulic autos too - which is seldom done - and usually needs the pan to be dropped for access. DSG? - I would stay well away from on a DIY basis! But be aware that, from what I've read, oil changes on them are critical I believe if they are to be reliable and last. Car mechanics magazine did an excellent article - Dec 2019 - which was 11 pages long and very detailed and is compulsory reading for anyone interested in them. I found it fascinating and have read it several times. Whilst they are very clever and I can see why they have gone in this direction with the design when compared to the old hydraulic boxes with torque converters, Whilst I might consider a hydraulic box a DSG looks far too frightening.
Finally - be very very careful about what you put back in. Engine and transmission oils are becoming very vehicle specific these days, using the wrong spec lube could end up very expensive indeed! Anyone remember the "melting" synchro rings caused by putting an API GL5 spec oil in a gearbox which needed the older API GL4 spec?