Generally, a free admission to police isn't inherently illegal, but its acceptance in the legal system is a tricky matter. The essential factor is whether it was obtained legally. Police must adhere to specific rules, https://panchanandshaw.com/blog/costs-in-pil-explained/