You can use Apple Pencil 2nd generation only with these iPad models:
iPad mini 6th generation
iPad Air 4th or 5th generation
iPad Pro 12.9-inch 3rd, 4th, 5th, or 6th generation
iPad Pro 11-inch 1st, 2nd, 3rd, or 4th generation
UP TO DATE COMPATIBILITY https://support.apple.com/en-us/108937