Afghan forces retake prison after deadly attack by IS group