You can't attack your own Pokémon, although there are many Pokémon with attacks that have some sort of effect on your active as the result of an attack. Take Tauros (XY 100). Its attack, Take Down, reads "This Pokémon does 10 damage to itself." If you have a strategy that requires you to take damage or place damage counters on your own Pokémon, you should look for attacks with this sort of effect.