That’s only true of external debt. I.e. debts owed to other currency areas. Government debt is just the number of funds from the currency originator (central bank) to it’s distributor (treasury). Both institutions are a subject of the nation state, which is controlled by the government. So it’s not a “debt” in any colloquial sense of the term, neither is it an intergenerational transfer, since the souvereign nation state is an institution that both creates and enforces it’s own currency... which by definition implies it can create as much money (“debt”/“credit”) as it seems fit.