Your insert might produce duplicate values in the BST, as it considers the new item as “bigger” if it is not smaller, meaning “equal” items are not equal, but the new item is “bigger” than the old.
Also, as your tree is not self balancing, insertion is O(n), as in a worst case scenario (input is a pre-sorted list) all insertions will happen rightmost.
What do I know? You haven’t shown the function. Though as in worst case your tree will be just like a linked list, it has the linked lists runtime and memory complexity of a linked list as well, assuming you have not done something completely borked in your implementation, but it can’t be better than a linked list.
Do it during insert, thats how properly implemented BSTs deal with it, regardless of the fact if they are balanced or not.
Deleting them after the fact, does require you to walk a lot of the tree, deleting offending nodes from the deepest (to the deepest is possible as well, but might cause a lot more reorganizing than necessary)…
I don’t really understand why it would make much sense to do that. However if you really do need to do that then it might make sense to add another key on each node that holds all the duplicates of that value. At least that way your BST structure still makes sense as a BST and still has the characteristics of a BST. As @NobbZ is saying, if you don’t handle the equal case the whole thing breaks.