"Do I link the photo directly to the ancestor on the people tab?"
The people tab is one place you can link photos to people. You can also do it from the Media workspace where you can link any media item to any person, source, or citation.
"Or do I have to create a fact?" and "What if there is no fact as such?"
1) If there are no facts/events that these photos support as evidence, then you should also link each photo to each person in it. In this case, you should also (a) record where you got each photo in the notes for each photo and/or (b) create a source for the book and link the photos to that source
2) If there are facts/events that these photos support, then you should create a source for the book and then cite the book for each fact/event supported by each photo. In the citations, include a link to each photo that supports the fact/event.
"If I link the photo to the ancestor in the person tab can I create a source?" and "Can I somehow link the photo to a source/source citation if the photo is added directly to the people tab?"
The order in which you add photos or sources doesn't matter. Only citations require that sources be there already, and the first step in adding a citation is pointing to an existing source or creating a new one to be used for the citation.
It doesn't matter where you do these things either. Photos can be added in the People, Media, and Sources workspaces. Citations can be added in all three workspaces as well (and sources can be added through the window that comes up when you add citations).