The quest is a buggy one. I gave the imp the courage potion, it proceeded to kill Frederick and wander off but the quest remains unresolved.