Move InvariantFunctor[F] instances to F companion object

This makes the instance locations consistent with instances for other
type classes. For example, the Contravariant[Equal] instance is in the
Equal companion object, and the Contravariant[Order] instance is on the
Order companion object.