Using your PC format your USB flash drive to FAT file format or ensure it is in FAT 32 file format.
To ensure your USB flash drive is in the required format,for windows 10 PCs, insert the USB into your PC. Then navigate to the USB storage icon, right click and click PROPERTIES, there you should see the file system format on your USB flash drive.
If the USB flash drive is not on FAT 32, then you need to Format it. To do so right click on the USB storage icon then click FORMAT. Ensure the file system is set to FAT32, then click START to format the USB drive.
Next open the USB flash drive and create a new folder and give it a name. This is the folder you will store your media files.
To keep things in order create a folder called VIDEOS to store video files and create another folder called MUSIC to store music files.
On your PS4, download the app called MEDIA PLAYER and ensure it is installed on the console.
Insert the USB flash drive in your PS4 then start MEDIA PLAYER.
Media player will display your USB flash drive storage. Click on it and navigate to the folder called VIDEOS (you created earlier on your PC) then it will display the movie files available. Just click on any movie file to play.
Repeat a similar process to play music files.
The PS4 supports several media file format including;
MP3, AAC, AVI,MP4, MKV,MPEG-2 PS,MPEG-2 TS, JPEG,BMP,PNG
For more information refer to the PlayStation 4 user guide