Criminologist warns parents they risk arrest under Scotland’s proposal to outlaw ‘conversion therapy’