You cannot use Windows 2012 R2 Foundation the way you are trying to.
In the Windows Server 2012 Foundation operating system, the server must be a member of a workgroup or, if joined to a domain, joined at the root of the forest as a domain controller.
In the Windows Server 2012 Foundation operating system, you will also receive a warning message if your server in an Active Directory domain has established a trust with a domain in another forest. If this occurs, remove the trust with the domain in the other forest.
For my money, the easiest way to fix this problem is to buy a proper Server 2012 R2 Standard license, and use that instead, but you may prefer a different course of action. I'm having trouble imagining why you couldn't make the Server 2012 R2 Foundation server a domain controller, at least temporarily, to resolve the licensing issue, and promoting a machine to a domain controller is pretty easy, so that's another option.