Darwin (unix/BSD) is open source [...] and by law, they can’t close that source code
Darwin is open source to avoid having to open source other components to macOS while still adhering to various licenses for software it depends on for. If Apple could legally close source that part of the OS they would in a heartbeat, they've already gone out of their way to make it nearly impossible to use by (iirc) obfuscating the compiler forcing users to reverse engineer the compiling process for newer versions of darwin.
I was really getting into the fediverse but I don't like twitter/facebook style social media and lemmy came in at the perfect time