Unfortunately, getting life insurance for someone who has been incarcerated is going to be difficult or even impossible. Life behind bars is an extremely high risk lifestyle, and very few life insurance companies will even consider writing the policy. Traditional insurance companies will not write the policies at all, and a high risk insurer is not likely to do so unless you are willing to pay extraordinarily large premiums. It is not a situation where one can definitively say that you can't get coverage, but doing so will be expensive and difficult, at the very least.
If a person already has a life insurance policy before they are arrested, or convicted if the person bonds out after the arrest, the insurance company will not cancel the policy as long as the premiums are paid. The risk is not any lower once the person has been incarcerated, but life insurance does not get reevaluated once the policy has been written, so the only way to end the policy is to stop making premium payments.
If you have power of attorney for someone who is incarcerated and can show that you or others would suffer financially in some way if the person died, you may be able to purchase a high risk policy, but that will depend on the laws of the state in which you live and the insurance company's own regulations. It is important to understand that even when you can show a need for insurance, people who are serving time are not entitled to the benefits of the Bill of Rights and very few insurance companies will underwrite such a policy.
After their release, purchasing life insurance can remain a problem. If probation or parole are involved, most insurance companies will regard the risks as being too high for coverage to be offered. As long as there is a possibility that you could be returned jail exists, insurance companies will not usually write a new life insurance policy.