A Balanced Tree Approach to Construction of Length-Flexible Polar Codes