no. shareholders are not usually the same legal person.
a corporation is a distinct "legal person" because it goes through "incorporation" which breathes a legal life into a concept.
a person does, a corporation has legally perpetual existence because the shareholders can endlessly transfer their shares to other persons and on death the shares are given as inheritance.
In which case, when the company distributes profits to shareholders, that is a transfer between people, and is taxed like other similar transfers. There is no double taxation - the company (one legal person) is taxed on income/profit, the shareholders (different legal persons) are taxed on the money they receive from the company.
a corporation is a distinct "legal person" because it goes through "incorporation" which breathes a legal life into a concept.
a person does, a corporation has legally perpetual existence because the shareholders can endlessly transfer their shares to other persons and on death the shares are given as inheritance.