If the child has been placed with you as a foster child by an agency or the government, you can claim a dependency exemption as long as the child has lived with you for more than half the year and the child doesn’t pay more than half of his/her support (foster care payments are provided by the agency, not you). If the child has been placed with you for a legal adoption, the child is treated as your own.
Gifts in excess of an $12,000-per-donee annual exclusion are subject to gift tax, but the tax may be offset by a gift tax credit.