mi is the question word, ami is a relative pronoun -- "which" is usually the best translation, as in "the book WHICH is black".
ami fekete is not an entire sentence; it's just part of one.
= mi fekete
We don't say "The book what is black" -- it's "The book that is black" or "The book which is black".
You are right.
But we could say: "I only eat what is black."
That would be "ami fekete", "ami" referring to a thing not expressly mentioned.
Btw, this, here, especially your examples, show a good example of when it is actually OK to use "ami", even though the noun it refers to is actually mentioned.
"The book, which I am reading" - "a könyv, amit olvasok".
I guess the case is helped by the noun being the last word of its clause, and by the second clause not being a restrictive one.