Seems like Variables is suitable for this.
Variables[ans]
(* Out[67]= {Subscript[p, 2], Subscript[p, 3], Subscript[\[Phi], 1], \
Subscript[\[Phi], 2], Subscript[\[Phi], 3]} *)
In[70]:= jac = Outer[D, ans, Variables[ans]]
(* {{0, 0, 0,
0, -1}, {0, -Subscript[\[Phi], 2] (1 - Subscript[\[Phi], 3]),
0, -1 + (1 - Subscript[p, 3]) (1 - Subscript[\[Phi], 3]), -(1 -
Subscript[p, 3]) Subscript[\[Phi], 2]}, {0,
Subscript[\[Phi], 2] (1 - Subscript[\[Phi], 3]), 0,
Subscript[p,
3] (1 - Subscript[\[Phi], 3]), -Subscript[p, 3] Subscript[\[Phi],
2]}, {-Subscript[\[Phi],
1] (1 - Subscript[\[Phi], 2]) - (1 - Subscript[p,
3]) Subscript[\[Phi], 1] Subscript[\[Phi],
2] (1 - Subscript[\[Phi], 3]), -(1 - Subscript[p,
2]) Subscript[\[Phi], 1] Subscript[\[Phi],
2] (1 - Subscript[\[Phi],
3]), -1 + (1 - Subscript[p, 2]) (1 - Subscript[\[Phi], 2]) + (1 -
Subscript[p, 2]) (1 - Subscript[p, 3]) Subscript[\[Phi],
2] (1 - Subscript[\[Phi],
3]), -(1 - Subscript[p, 2]) Subscript[\[Phi],
1] + (1 - Subscript[p, 2]) (1 - Subscript[p, 3]) Subscript[\[Phi],
1] (1 - Subscript[\[Phi], 3]), -(1 - Subscript[p, 2]) (1 -
Subscript[p, 3]) Subscript[\[Phi], 1] Subscript[\[Phi],
2]}, {-Subscript[p, 3] Subscript[\[Phi], 1] Subscript[\[Phi],
2] (1 - Subscript[\[Phi], 3]), (1 - Subscript[p,
2]) Subscript[\[Phi], 1] Subscript[\[Phi],
2] (1 - Subscript[\[Phi], 3]), (1 - Subscript[p, 2]) Subscript[p,
3] Subscript[\[Phi],
2] (1 - Subscript[\[Phi], 3]), (1 - Subscript[p, 2]) Subscript[p,
3] Subscript[\[Phi],
1] (1 - Subscript[\[Phi], 3]), -(1 - Subscript[p, 2]) Subscript[p,
3] Subscript[\[Phi], 1] Subscript[\[Phi],
2]}, {Subscript[\[Phi],
1] (1 - Subscript[\[Phi], 2]) + (1 - Subscript[p,
3]) Subscript[\[Phi], 1] Subscript[\[Phi],
2] (1 - Subscript[\[Phi], 3]), -Subscript[p, 2] Subscript[\[Phi],
1] Subscript[\[Phi], 2] (1 - Subscript[\[Phi], 3]),
Subscript[p, 2] (1 - Subscript[\[Phi], 2]) +
Subscript[p, 2] (1 - Subscript[p, 3]) Subscript[\[Phi],
2] (1 - Subscript[\[Phi], 3]), -Subscript[p, 2] Subscript[\[Phi],
1] + Subscript[p, 2] (1 - Subscript[p, 3]) Subscript[\[Phi],
1] (1 - Subscript[\[Phi], 3]), -Subscript[p,
2] (1 - Subscript[p, 3]) Subscript[\[Phi], 1] Subscript[\[Phi],
2]}, {Subscript[p, 3] Subscript[\[Phi], 1] Subscript[\[Phi],
2] (1 - Subscript[\[Phi], 3]),
Subscript[p, 2] Subscript[\[Phi], 1] Subscript[\[Phi],
2] (1 - Subscript[\[Phi], 3]),
Subscript[p, 2] Subscript[p, 3] Subscript[\[Phi],
2] (1 - Subscript[\[Phi], 3]),
Subscript[p, 2] Subscript[p, 3] Subscript[\[Phi],
1] (1 - Subscript[\[Phi], 3]), -Subscript[p, 2] Subscript[p, 3]
Subscript[\[Phi], 1] Subscript[\[Phi], 2]}} *)