The costs of casing/screen/battery/wifi/storage/software development/GPS/GSM etc do soon mount up. The RPi may have the same CPU and ram as a phone, but it's a far more basic device. If you want a better comparison to make high end phones look expensive, compare them to the Moto G or similar.