Hi Peter. Welcome to justanswer.
Can you tell me (in gallery) under which folder these unwanted images appeared?
These type of things happen if you download anything from an unsafe source (like apps or other data). Better use an anti virus on your phone. There are so many available for free in Google Playstore. And avoid downloading apps from source other than Playstore.
Do you have any other query?
Thanks for the ratings Peter. Enjoy the weekend.