Hungary's president has refused Prime Minister PΓ©ter Magyar's demands to step aside, setting up a constitutional clash.