Changing the subject, the underlying problem is abusing modals. One for "Your session is about to expire" that's OK, but for "Add Fruit" you can create an editable new fruit row and allow undoing the action(s).
BTW, in my app, I only use "Cancel" for having an element to focus on when there's a destructive action. Other than that, the user can click outside the dialog. Which I mention to ask you: do make the click area outside the dialog a link as well?
I agree with you that modals are abused. Modals should - in my opinion - be used for immediate actions such as your example.
Side panels however are fine in my book. In the end, we're talking about the same thing: example.com/fruits/new - Navigating (there you have it) to this URL should provide the user with an interface to fill out a form to create a new fruit.
In practice this could just as easily be a side panel triggered from the fruits list page, by clicking on the "new fruit" link. The URL should reflect that UI state change.
---
Also, link vs. button is an a11y concern and the guidelines use buttons: https://www.w3.org/TR/wai-aria-practices-1.1/examples/dialog...