Validate on Condition in Generated Form


I have a form field Variable in a user task of type Enum in which it is having two values Approve and Reject.
Can I dynamically set the Validation(required) for another field “Reason” if the user selects Reject and tries to submit the form.
That means he should be only asked for Reason when he select the Reject value and he can neglect the Reason if he approves.

Please help me in achieving it inside the modeller without using Java code.

Thanks and Regards,