A man who claimed he "genuinely believed" he was Jesus has been moved to a secure mental health facility ahead of his sentencing for plotting to kill a prosecutor.