Iranian ex-deputy defence minister Alireza Akbari has been sentenced to death after being accused of spying for the UK.