Adding a button to the model doesn't make sense, this would break the logic-presentation separation. What you want is to modify the view. The usual way to do what you want would be simply to make it so that if you click on the header in the appropriate column (the one with checkboxes) all checks will go on or off. But if you want to do it "your way", you can use QAbstractItemView::setIndexWidget() for instance or you can use QAbstractScrollArea::setViewportMargins() to move the viewport down and place the button in the extra space between the header and the viewport.
Of course you might also make the header checkable as in the image below.
Bookmarks