You can change your beneficiary at any time while you are living, and the distributions after you die will be paid over that beneficiary’s life expectancy (unless they cash out).
It is very important to name both primary and contingent beneficiaries while you are living to allow for greater flexibility and “clean up” after your death. For example, your spouse could disclaim some benefits so a grandchild could inherit. No new beneficiaries can be added after you die (unless your spouse names new ones with a rollover), so make sure you include all appropriate ones.
Some employer-sponsored plans (401(k), pension and profit sharing plans, etc.) have restrictions on beneficiary distribution options. But under a new rule, any beneficiary may now inherit employer plan assets and roll them into an IRA in the name of the decedent, continuing the tax-deferred growth over the beneficiary’s own life expectancy. (Some restrictions apply.)
If your plan will not let you do what you want, rolling your account into an IRA will usually give you more options. If your money is already in an IRA and the institution will not agree to your wishes, move your IRA to one that will.