There are many reasons a person would set up a shrine for their beloved dead. One common reason is to honor the deceased and the relationship that you had with them in this life. Many people believe that the dead have the capacity to influence the world and to petition on the behalf of the living with the deities. Some shrines are elaborate affairs and maintained by the community. This would include things such as memorial garden established in the community, a memorial monument, such as the Tomb of the Unknown Soldier, or a graveyard. Other shrines are very private and simple. This could be a collection of photos of the dead, the regular placement of flowers, and the burning of incense or candles.
Most commonly, people will honor their ancestors and departed friends. There is, however, an established habit of roadside shrines being hastily constructed by the community for persons who died of violence or from a particularly egregious car accident. One does not need to only focus on the dead whom they are related to or have had some sort of personal connection to during their lifetime. It is also possible to honor deceased persons who have been highly influential in one's life by way of their works or otherwise have made an impressionable impact on their life. There is also a sub-practice of establishing a memorial shrine that includes deceased pets.
The simplest ancestor shrine is the placement of a memento or an item that symbolizes the dead. More complex shrines can be made into free standing structures or special cases that hold mementos of the dead and offerings to the dead. My personal ancestors shrine consists of a shelf. On that shelf is an assortment of items that I associate with my familial dead and deceased friends. There is a small vase which I will put an offering of flowers in on a regular basis. I also have an electric candle that I keep lit all the time for them as well. (The lit candle, in my usage, is a beacon that helps the bring the kindly dead to me and show my beloved dead that they are welcome in my home.) I also have a little box that I will put physical offerings in.
As you may have intuited, one may leave offerings for the dead. There are a variety of ways to do this. One can lay flowers at the deceased's grave site. This is a very common offering for the dead. Another thing that can be done is to light candles or burn incense for the dead. The candles are found quite frequently in Christian Catholic influenced settings and faith systems (such as Santeria or Voudon). The practice of burning incense for the dead has been done as long as there has been recording of people burning incense. There are some people who will give food offerings to the dead. (In urban America, there is a semi-regular practice of pouring out a bottle of alcohol in memory of the dead.)
In addition to leaving offerings for the dead, a person can pray to and commune with the dead. This is actually a very common practice. Within Christian belief systems, one will find frequent reference to praying to persons who have deceased and believed to have joined the company of their deity in the paradise referred to as Heaven. The Catholic community refers to these deceased persons as saints. (Saint is a generic term for the deceased who are in good standing within the faith. Saint as a title refers to deceased persons who are especially blessed and believed to have considerable intercessory powers and capable of performing miracles for those who petition them.) Praying to the dead and giving them offerings is a practice that helps strengthen familial ties and bolster one's sense of filial duty, when the veneration focuses specifically upon family.
Maintaining a shrine for the dead can be quite complicated. At it's core, maintaining a shrine requires the regular cleansing of the shrine and ensuring it is in good condition. It also includes the disposal of the remains of offerings in a fashion that is in proper accordance with the beliefs of the persons who are maintaining the shrine.