Hi,
Syntax like
Security!*[System[(EventID!=4624)]]
is correct.
If you already have existing data collection rule edit that rule instead of creating new one. If you create a new one to exclude event ID that is collected via another data collection rule that will not work. Also it depends what kind of configuration you are using for Windows Security events - All, Common or Minimal. If it is Common or Minimal you just need to remove the event ID that you want to exclude in the xPathQuery rather adding value for exclusion. If you use All you will need to add the xPath query to exclude the event.
Please "Accept the answer" if the information helped you. This will help us and others in the community as well.