Self-interest on the part of economic actors helps achieve society's goals because that self-interest can be the basis of a strong economy.
Let us look at the actions of entrepreneurs, for example. When entrepreneurs come up with major new ideas, they not generally doing so as a way of being philanthropic. Instead, they are trying to make money. As they make money, they help others to be better off. When Bill Gates started Microsoft, for example, he made many other people better off. He made his own employees better off by employing them at a successful company. He made society as a whole better off by making it so much easier for us to use personal computers. In these ways, his self-interest (the desire to make money) helped achieve societal goals (providing jobs for people, providing consumers with the goods they want to use).