The dirty little secret is that there is little payback for retailers to do so.
Walmart could do it at scale, but they already can put megawatts of solar on existing roofs for their stores. Article mentions several states where solar is discouraged to protect monopolies. Not to mention another article out saying Republican-led states are actively punishing corporations who reduce their emissions. Walmart isn’t going to see a realistic payback from that investment, and could even face backlash. They also sometimes get tax credits and incentives from the power company to build a Supercenter in a certain area. They do however buy into solar farms to offset their carbon.
Other retailers (Trader Joe’s or Starbucks) it wouldn’t make sense for, most lease their buildings and don’t have enough expertise to take this on. Commercial property owners wouldn’t care about this.