First, be sure you qualify to claim the child. The custodial parent has first priority on claiming the children on her taxes; regardless of the amount of support provided by the non-custodial parent. "I take care of my son" is not tax terminology.
The IRS goes by physical custody, not legal custody. The non-custodial parent can only claim the child as a dependent if the custodial parent gives permission (on form 8332) or if it's spelled out in a pre 2009 divorce decree. . Even if a divorce decree, dated after 2008, gives the non-custodial parent the right to claim the child, he must still get form 8332 from the custodial parent. A properly worded decree should require her to provide that form. https://www.irs.gov/pub/irs-pdf/f8332.pdf
For 2020, it depends on how long you were physically separated. If less than 6 months, than only one of you can claim him. See the "special rule" below if you were separated longer and for future years.
An unrelated person (e.g. parent's friend) can only claim a child if they lived with the child all year. Even then they cannot claim the child tax credit or Earned Income Credit, because they are not related. They can only claim the $500 other dependent credit.
If someone else claimed your child inappropriately, and if they file first, your return will be rejected if e-filed. You would then need to file a return on paper, claiming the child as appropriate. The IRS will process your return and send you your refund, in the normal time. Shortly (up to a year) thereafter, you'll receive a letter from the IRS, stating that your child was claimed on another return. It will tell you that if you made a mistake to file an amended return and if you didn't make a mistake to do nothing. The other party will get the same letter you did. If one of you doesn't file an amended return, unclaiming the child, the next letter, from the IRS, will require you to provide proof. Be sure to reply in a timely manner.
There is a way to split the tax benefits. For future negotiations with the other parent (and maybe even for this year) the following info may be of use:
There is a special rule in the case of divorced & separated (including never married) parents. When the non-custodial parent is claiming the child as a dependent/exemption/child tax credit; the custodial parent is still allowed to claim the same child for Earned Income Credit, Head of Household filing status, and day care credit. This "splitting of the child" is not available to parents who lived together at any time during the last 6 months of the year; then only one of you can claim the child for any tax reasons. The tax benefits may not be split in any other manner. A parent cannot split benefits with a friend, only the other parent.
Note in particular that the non-custodial parent can never claim the Earned Income Credit, Head of Household filing status or the day care credit, based on that child, even when the custodial parent has released the dependency to him.
If you had physical custody more than half the nights of the year, then you are entitled to claim the child as a dependent. If you and your wife both had physical custody more than half the nights of the year (because you separated in October, for example) then the parent who has the right to claim the child is the parent where the child lived the greater number of nights.
If you are the parent entitled to claim the child as a dependent, you will simply file a correct tax return. If you are blocked from e-filing, then print your return, sign it, and mail it in. The IRS will eventually investigate the duplicate dependent claim and require both taxpayers to furnish proof. (You do not submit proof when you file your tax return.)
If your wife is the parent who was entitled to claim the child as a dependent because she had custody more nights than you, but your wife allowed a friend to claim the child instead, then you can’t file a tax return to trigger an automatic review. You could file a fraud report with the IRS and that might start the necessary investigation.
The parent who had custody the larger number of nights can transfer the dependent claim to the other parent by signing a form 8332. Sometimes this is voluntary, if the parents can cooperate, and sometime this can be ordered by the court as part of a custody settlement. However, a dependent can never be transferred to an unrelated person using this form. The only way in which an unrelated person could claim your biological child as a dependent is if the child lived in that person’s home for all 365 nights of the year and you never had custody even one night (plus a couple other conditions that I’m skipping over for now).