In GDScript, I think that Dictionary is the closest thing to a Set.
The Set elements would be the Dictionary keys. The values don't matter, and could be any type, such as int or bool.
You would need to implement operations such as union, intersection and difference, as functions.
You could encapsulate it in a class, with the Dictionary as a class property and the Set operations as class methods.
Since GDScript doesn't support generics (types as class and function parameters), you would need a different class for each Set element type. Maybe you could use Variant, but then there would no compile-time type-checking.
Dodo_87 Is there a need to have a data type Set? (What about Stacks? Queues? All sort of collections?)
GDScript is designed as a simple, built-in scripting language. I guess it's debatable how far to go in adding features, or whether to replace it by an existing feature-rich language such as C# (which is already an option), Kotlin, Dart or Swift.