Amazon’s hiring bar has historically been very low, with a philosophy that if it doesn’t work out you can always just fire the person later. A similar philosophy exists for staffing up teams for speculative projects. If it doesn’t work out you can just axe the whole division after a couple of years. Periodic large layoffs are a natural consequence of operating like this.