Why is Xiaomi so cheap even with high specs?

Quick & Large sized Production
The biggest advantage what Xiaomi has today is their production alignment and products platform across different countries. Like established brands Samsung, Nokia etc - they offer almost same models in most of their operating countries and that gives them advantage to achieve real economies of scale. They have the ability to squeeze margins of their suppliers and in turn promise them bigger volumes and thus top lines with timely payments. They were the first one to set up their factories in India to take advantage of Make-In-India program.
Always in-flavor models
When Xiaomi launches any model - they make sure that they time the market right. They never experiment with old processors or technology - which gives them lot of favours from the bloggers & consumers. I will explain the bloggers part a little late here but consumers always prefers the latest technology. Today, they purchase the phone not by looks but also by the “what-is-under-the-hood”.
Use of Influencers
This is probably the first brand, which has used the social influencers in the very best manner. They hold conferences, parties and take their feedback very seriously. If you are an influential blogger - Xiaomi will ensure that they keep calling you for feedback and involve you. This helps to create buzz in social media.
Success in India
Xiaomi’s success in India also largely thanks to e-commerce companies who were looking to acquire new customers and wanted to show higher GMV to their investors or bosses. That has resulted into almost zero cost of sales to Xiaomi. Today - market places like Flipkart or AMZ does advertisement for Xiaomi models because they are getting users or buyers and that help them to add into GMV.
Xiaomi is not only a mobile company
When you buy a Xiaomi phone, it usually comes with few apps - which you may not required. These apps are of non-removable nature. Over a period of time, people start using these apps and Xiaomi makes money from the advertisements which they are placing inside these apps. Now imagine the kind of large customer base Xiaomi holds and calculate the revenue.
Scarcity generates demand
In the initial phase, they have ensured that their supply will remain lower than demand. This creates lot of fury among customers that they did not get blah blah model on blah blah date flash sales. Customers complained over social networks, and again company enjoyed publicity. People who did not know Xiaomi, came to know about it.
Avoiding unnecessary investments
Even today in India, which contributes almost 60% of their overseas sales - their total employees in India are less than 100. Now consider other brands and you will be able to calculate the savings of not only salaries but other stuff also. Also lean organisations will always make faster calls. Bigger ones moves like elephants. They take time to respond to market.

Though, I am not selling Xiaomi on my website - OnlyMobiles.com but I have tremendous respect for this company and I wish them good luck. I hope they will keep keen eye on their after sales network and improve customer service a bit.