That's the point here. By giving away instead of selling what has a market value one denies the thing (or at the very least contributes to the thing's price growth) to people who worked hard to get it and gives it to people who did not.
I am not questioning the owner's right to do it, but morality of the action. Whether every immoral action should be also illegal is another question.
You are missing the point. It was not on the market in the first place. You can't impose rules about other people's property or you are presuming to be the owner of the property. There can be longer-range issues at play, like for example that wealth is a network phenomenon, poor people are much more likely to become criminals. And in saying that, I am not condoning it, the people who are poor and revert to theft to meet their basic wants are not moral actors, any more than a big player robbing a bunch of trusting clients. But I can't become rich without customers, and neither can anyone. Humans are wired to in part seek the interests of the group as part of their securing their own position.
Ignoring this leads you to the dog eat dog tyrannical power structure.
The point here is that the owner of the thing has to make a choice between some alternatives: put for sale, give away, keep in a closet and so on. And further, that the most morally and socially beneficent alternative is to put for sale.