They did represent the shareholder interest. This compensation deal delivered a crazy increase in company valuation. Tesla went from selling 200k vehicles to selling over 1M.
Given how much control Musk exerted over the process it's less that the board represented shareholder interests and more that the shareholders happened to benefit despite not being represented and not being fully informed on how the compensation package was put together. Perhaps a subtle distinction, but important in the eyes of the law.