The option to abandon a transaction is only available if a) it has not been abandoned before, b) neither the transaction or a conflicting transaction is confirmed, and c) the transaction is not in your own node’s mempool.
Note that even when you abandon a transaction it might still be retained by other nodes. The only way to be sure that your original transaction cannot be mined in the future is to create a conflicting transaction that spends some of the same inputs and get it confirmed in the blockchain. This is exactly the intent behind abandontransaction
. You inform your wallet that you are no longer pursuing confirmation for the abandoned transaction which instructs the wallet to permit reuse of the inputs used in it.