Yes, the tag definitely counts against the CAP. The tag is basically a 1 year salary for the player. It counts against the cap immediately and becomes guaranteed once the player signs the contract. Belwo are the rules regarding the cap:
Franchise or Transition Tag – any player who receives the Franchise or Transition Tag (other than the Exclusive Franchise Tag) is still technically a Free Agent, but is restricted by the Tag. A player under the Tag does count against the Salary Cap, at the amount of the Franchise or Transition Tag tender amount.