The measure of Elon's wealth is absolutely misleading. It is a useful metric for comparing against other wealthy people, but it is not useful to compare to other things, like solving world hunger, etc.
Let's say you and I had apple orchards of differing varieties and we wanted to compare them, we could look at how many apples our orchards produce over 20 years and price them in today's dollars. This could allow me to say for example that my orchard is worth billions more than yours. You could look at those billions and say that those apples could feed the homeless and that I am greedy for not using them as such. The obvious problem with this is, those apples are not all available today, it is value that is produced overtime that is being measured and not it's immediate value.
So why is this the same as Elon's wealth? If Elon's assets were sold immediately, it would crash the market value of those assets and Elon would get far less for them, in addition he may not be able to sell all of them because the market demand is simply not there for them. In much the same way that there is not enough apples to feed everyone at a given time, there are not enough buyers of Elon's assets even at a high discount, though some may go into debt. So if the government confiscated his wealth they would be faced with the same issue of if they confiscated an apple orchard and come to realize there were never enough apples to feed everyone.
Someone's net worth is simply an accounting trick that is useful in some comparisons but completely useless in others.