Confirm dialog with optional checkbox

I am working on a web application where I need to display an alert.

In this alert, clicking on "No" will hide the alert and clicking on "Yes" will remove the selected element (in example).

I would like to add a checkbox like "Remove all sibling elements" of that particular selected element.

Is it recommended UX to combine confirm choices and possible action through a checkbox?

I have read this part of Material Design Guidelines, nothing about checkboxes.