JQL is used to search for issues.
The scenario you describe can be handled using Automation Rules.
Automation rules allow you to use if/else-if/else blocks. Are you familiar with the Automation Rules feature? If not you may want to look on YouTube to find video tutorials. There are several available.