I had to change your question as you are not allowed to ask multiple questions. Please remember in future to only ask one question.
Does this story teach us the dangers of fantasy? In what sense is the flight of fantasy that Peyton Farquhar embarks on dangerous? I am not convinced that Bierce deliberately tries to present the hallucination that Farquhar experiences in a negative fashion. After all, the protagonist is presented as acting instinctively in the fact of death. There is no sense in which Peyton Farquhar is choosing to live in a fantasy world, and I don't think we can detect that Bierce judges his character for doing this. Rather, I feel that this story is an examination of the psychology of someone facing inevitable death and shows us the kind of impact that death has on someone in this situation. Note how, in Farquhar's case, the terror of death distorts perceptions of time, heightens the senses and creates elaborate fantasies of escape. Consider the following description of Farquhar:
He was now in full possession of his physical senses. They were, indeed, preternaturally keen and alert. Something in the awful disturbance of his organic system had so exalted and refined them that they made record of things never before perceived.
Therefore, I have to disagree with the crux of your question. Bierce is not trying to expose the dangers of fantasy. This story acts as a psychological examination of the impact of inevitable death on the human psyche.