To use your PS4 controller on a PS5, connect it to the PS5 with a USB cable and press the PlayStation button on the controller.
To connect AirPods to PS4 or PS5, you'll need to pick up a Bluetooth adaptor with audio capabilities, since Bluetooth doesn't come with the consoles.