This is a PC issue that has existed forever, as far as I can tell. I'm sure it's been documented before.
Observed: When a user drags an item from their inventory into an in-game mail and misses one of the item slots at the bottom, the discard confirmation dialogue is displayed.
Expected: When a user drags an item from their inventory into an in-game mail, it should always result in either attaching the item or displaying the "you must be near a mailbox to attach an item" dialogue.
The current functionality makes it waaaaaay too easy to accidentally discard items, particularly since the boundaries between item slots also count towards discarding, and the border between the rightmost and second-rightmost items is by default precisely aligned with the "yes, discard it" button.
2