and if I try to do a case analysis on k≅k′ (i.e. by using C-c C-c from the Emacs frontend) to make sure all the implicit arguments are properly matched with respect to their constraints imposed by the refl, I get

Cannot decide whether there should be a case for the constructor
refl, since the unification gets stuck on unifying the
inferred indices
[{.Level.zero}, {Counter n}, k]
with the expected indices
[{.Level.zero}, {Counter n′}, k′]

The original problem is that knowing Counter n == Counter n' doesn't imply n == n' because type constructors are not assumed to be injective (there's a flag --injective-type-constructors for this, which in fact makes the match go through, but it's known to be inconsistent with excluded middle), so while it can conclude that the two types are equal it won't rewrite n to n' and so you get that error when it later checks if k and k' are unifiable.

Since Counter n has exactly n elements, it's actually possible to prove Counter is injective using something like the pigeonhole principle (and maybe decidable equality for naturals), so you could do without the n ~= n' argument, though that'd be messy.