I personally would defer judgement on why Amazon is leaving; Alibaba tends to be the most competitive of the Chinese internet companies, and has a corporate culture very similar to Amazon (frugal, but with 996).
But Alibaba isn’t really Amazon’s main competitor, they are much more B2B than B2C, it’s only when you throw in TMall or Taobao that comparisons become more apt. When I was living in Beijing, my wife and I never used Alibaba, it was always JD.com or some other consumer oriented site, and even Amazon sometimes (though mostly because the Microsoft China trade Union kept giving us gift cards as a kickback).