Market demand is not the only factor, though. Manufacturers make design decisions based on a variety of factors, from supportability and manufacturing efficiency to alternative profit vectors like bloatware and proprietary ports.
If someone made a slider phone with a physical keyboard, it could be the best selling phone on the market without making the most money for the company.
There was a movie about this last year. It was based on a true story, but strays a bit from what actually happened. It’s pretty good. It’s called Hitman.