Let $t = 1+q+q^2+\dots+q^n $ then each of the equations (1) and (2) implies that $24t+1$ is a square (namely, $24t+1=(12k+1)^2$ and $24t+1=(12k+5)^2$, respectively). For $n=2$ that leads to a Pellian equation (with possibly infinitely many solutions), for $n=3,4$ to an elliptic curve (with finitely many solutions, if any), and for $n>4$ to a hyper-elliptic curve (with no solutions for most $n$).
Cases $n=3,4$ are easy to solve.
For $n=3$, integer solutions are $q=-1, 0, 2, 3, 13, 25, 32, 104, 177$ out of which only $2,3,13,25,32$ are powers of primes. For $n=4$, integral solutions are $q=-1,0,1,25,132$ out of which only $25$ is a power of prime. These numerical values are computed in SAGE and MAGMA.
Also, for a fixed value of $k$, it is possible to verify solubility of the given equations by iterating all possible $q$ dividing the l.h.s. minus 1. In particular, equation (1) has solutions only for the following $k$ below $10^6$: 1, 2, 3, 15, 52, 75, 1302, 32552, 813802. Similarly, equation (2) has solutions only for the following $k$ below $10^6$: 1, 10, 260, 6510, 162760.