Afghanistan says its forces have killed 28 fighters and captured 32 crossing from Pakistan, while Islamabad has rejected claims they were Islamic State members.