If you want the iPhone or iPad wallpaper to change automatically when switching between light and dark mode, you can use special wallpapers provided by Apple that include both light and dark versions. See how you can make the necessary adjustments.
First, open the "Settings" application on your iPhone or iPad.
In Settings, click "Wallpaper".
In Wallpaper settings, click "Choose a New Wallpaper".
On the "Choose" screen, select the "Stills" category at the top of the page.
In the "Stills" category, select a wallpaper that includes the dark mode icon, which looks like many concentric circles cut in half.
On the next screen, press "Set" and then decide if you want to see the wallpaper on the lock screen, on the home screen (Home Screen) or both.
After that, close Settings and switch from light mode to dark mode (or vice versa) by opening control Center, holding down the slider brightness and pressing the dark or light mode power button. After you change it, you will notice that the wallpaper changes now automatically.
Source of information: howtogeek.com