The process of laying a corpse in a coffin is called kistin in Scotland. This was more than a necessary act in a funeral parlour, it was a religious ceremony and either the minister himself or one of his elders was performing the solemn task. The reason being, there was a law concerning the way a body should be buried.
Act for Burying Scots in Linen
“In the second Session of the First Parliament of James VIII, held at Edinburgh, 1686, an Act was passed called the ‘Act for Burying Scots in Linen’, in which it was ordained, for the encouragement of the linen manufacturers within the kingdom, that no person whatsoever, of high or low degree, should be buried in any shirt, sheet or anything else, except in plain linen or cloth, of Hards made and spun within the kingdom, and without lace and point.”
Life and Times of Rev. John Wightman, D.D., of Kirkmahoe (1762 – 1847)
This was of course decreed to strengthen the local economy and ward-off the Dutch cloth influence. To be able to control that, the ministers were supposed not only to register every death but also control that the law was being followed.
Generally, a funeral was of high importance in the community and very much a social event with explicit rules. Especially in the 18th century funerals were lavish affairs and the family spent as much as they could on food and drink and general services rendered..
sources and further reading:
Margaret Bennett: Scottish Customs From the Cradle to the Grave. Birlinn, Edinburgh, 2004